If they can detain you then how are you free to leave?
They have the same rights an any other citizen to detain you and call a police officer.
Citizen detention laws vary by state, but generally there's a fairly high standard of probability that you committed a crime.
https://www.tsa.gov/blog/2016/07/03/tsa-myth-busters-do-tsa-...
If they can detain you then how are you free to leave?