Sometimes, the English letter spelling of a place may be changed, but the airport code remains a vestige of the old spelling:
PEK = Beijing (Peking)
KWL = Guilin (Kweilin)
BOM = Mumbai (Bombay)
Or the name of the airport changes, but the code references the old name:
ORD = Chicago O'Hare (Orchard Field)
YFB = Iqaluit (Frobisher Bay)
SDA = Bagdad (Saddam Hussein)