Gauge vs absolute pressure
A boost gauge reads pressure above the air around you. The engine (and a compressor map) cares about absolute pressure: boost plus atmospheric pressure. At sea level, 12 psi of boost is about 26.7 psia; at 5,280 ft the same 12 psi is only about 24.1 psia, because there's less air to start with.
Pressure ratio
pressure ratio = (boost + ambient) ÷ ambient. It's the vertical axis of a compressor map. The same boost at altitude means a higher pressure ratio, so the turbo works harder and runs hotter. That's why a turbo that's fine at sea level can run out of breath in the mountains.
Altitude and NA engines
A naturally aspirated engine makes power roughly in proportion to absolute pressure, so it loses about 3% per 1,000 ft. A turbo car with boost control can make most of that back, so altitude hurts it far less.