You. Cannot. Be. Forced. To. Unlock. A. Phone. With. A. Password.
(In the United States)
If you are caught with your phone in a bad situation, fight to manage to get it to shut down. Android will be stuck in a locked out state where biometrics are disabled. Im sure iphones can do something like that but rethink bringing your stupid iphone to a protest. Ask for a lawyer. Do not talk, do not answer questions, do not say anything else.