Largely a company can choose their customers; they’re not forced to transact with anyone. There are some exceptions of course, largely based on the reasons for not transacting. Being publicly traded doesn’t really matter here directly.
I assumed that it's his/their fiduciary duty to maximize profit, and if the current excutive team doesnt do that, they will be replaced with a team that will.
Execs have wide latitude to do their jobs, and considering the current circumstances I could see them deciding that declining to take police as customers would be better for the company long term.
This would be a very defensible decision legally (not a lawyer). You're right that it could plausibly lead to some sort of shareholder rebellion, but I'd be surprised.