Ferrite bead for mobile headset
The ferrite choke is a CM impedance transformer, so CM noise coupling is high Z at RF and low current.

In order to attenuate , a simple RF cap shunt to gnd creates a large impedance divider for RF so yes a Gnd is necessary and any loops inside th box benefit from shielding at mobile frequencies, but if you gave a ground plane, and good RF decoupling, it is not necessary to have a grounded metal box.

CM chokes also come in SMT for board mount, ~100uH with high SRF, to make a Pi (LP) filter. A good  search can visualize what I said.