The actions of the police during stop and search and arrest procedures are governed by the Police and Criminal Evidence (PACE) codes. These are informed by the Equality Act 2010.
Gender reassignment is defined in the Equality Act as a “personal, social and sometimes medical process”. Therefore, even if the state does not officially recognise your gender, and you do not have it on your documents, your gender should be protected when being stopped and searched or arrested, because gender reassignment – defined as a “personal, social and sometimes medical process” – is a protected characteristic under the Equality Act.
UK law is currently unclear about non-binary people. This does not mean that if you are non-binary you need not be assertive about your gender if you wish.
No police officer has the right to ask you whether you have a Gender Recognition Certificate.
The law is (unsurprisingly) still transphobic – Annex L of the PACE codes, which explicitly addresses gender reassignment, says that police officers should ask you your gender and respect it, unless your “predominant lifestyle” is different from what officers decide. This does not mean you cannot insist on having your gender recognised.