That's why all phones should have a decoy feature so that when asked to produce a password, you just give them the decoy pass, and it unlocks a clean profile with no way for them to find anything personal, and or incriminating.
One example I found off Google, though I've heard of others:
https://arstechnica.com/gadgets/2012/10/nokia-patent-may-be-...