Yes they have the right. Stupid decision though.
I don't see it that way. I think it's a smart decision. They are reducing the risk to their customers. And more customers may fly, if they know everyone will be wearing masks.
Masks aren't perfect protection, but they do help. And they help more if everyone wears them.
If I had a choice between two stores. And one required masks, that's the one I would shop at.