They cannot know everyone- they were doing their job. Would the Royal Knob prefer they did not do their job.
Security works when everyone is aware of the procedures - Including ID person(s) who you are not familiar with.
Think of how large a number of staff they have.
The largest problem that Security has is with those that think they are above it.
And that leads to mistakes.
No apology should have been needed.
Prince Andrew ‘grateful’ for apology after Buckingham Palace police confront him, demand he identify himself | National Post