Chemist is really an old name for a pharmacy in the UK. When I was growing up you went to the chemist for your prescription medicines but at some point, I think in the 90s, they all rebranded as pharmacies. Boots the Chemist became Boots Pharmacy.
I first learned the word pharmacy as pharmacie when I was learning french shops at school.
It is still common to refer to them as chemists despite what it saying pharmacy on the sign.