No.
The DHS rule only applies to flights inbound to the USA.
It is often either ignored or loosely enforced. Here, either the crew were sticklers, there was a FAM or DHS inspector onboard, or someone on the crew has recently been dinged.
OP got more than entitled to. If the crew had correctly enforced the rule, each passenger would have been requited to sit in the cabin on that passenger's boarding pass.