To hold anyone against their will is illegal. I guess if you were restraining a suspected criminal while you were waiting for the authorities to arrive would be OK. But anything other than that is definitely illegal.
This all depends, are you simply turning a deadbolt, or are you placing an object(s) to completly seal doors and windows? The first i think is legal, but if you completely block thier exit paths, i think that isn't.
That depends on the circumstance - if you're locking them in there because you want to restrain them, then yes - it's illegal... If you are performing a citizen's arrest, then it's legal.