Imprisonment, false imprisonment, physical restraint, or blocking ingress or egress is used to increase stress. Even if temporary, the tort of "false imprisonment" ("false" because it is unlawful) creates liability. Not letting people move without physical restraint is never appropriate in good faith negotiation in deals and disputes.
Pushy sales person blocking you from the doorway. Having you wait in a locked room during a negotiation. Backing you into a corner. Harmful or offensive touching (assault and battery) to gain concessions.
Consider your situation and your physical safety above all. Situation awareness and assessment is the first step. Secondarily, say "I have to leave now." And leave! If they push back in any way, verbally or physically, ask: "are you preventing me from leaving?; "are you blocking me from leaving?"; - then leave. There are both civil and criminal sanctions, but your primary objective is to get out safely. Consider getting a restraining order if the condition is serial or mobile. The longer you stay in a threatening restraining situation, the higher the risk according to one author. If you just freaked out and start to blame yourself, in an abundance of caution, if you re-engage, bring a witness in a public setting or engage a security detail.