More of a stopgap measure until an ownership system can be put in place, a “Don’t loot” dialog menu option would prevent companions from A) stealing all your shit, and B) filling up all their inventory with useless crap so they don’t have any room for important things like meds, bandages, ammo, etc.
or to simplify it, have partied npcs have a command window to tell them to quickly do things like clear a space baced on a map tile like, Loot this house or this quadrent of hospital. it could also be used to tell them which targets to focus attacks on and such