What happens is valves (especially leather valves) curl up so they don't shut properly.
Also Mylar valves come unglued or break and fall off.
Mechanism: the reed's pitch is determined primarily by the mass and stiffness of the reed, but the size of any air-filled chamber near the reed has a second order effect on the reed's pitch, as the air itself has some mass and also some springiness because of its compressibility. The difference between an open and closed valve is thus enough to make a few cents difference to the reed's pitch.
That's why valves are the first thing to fix if the instrument is out of tune.
But then, the reeds themselves do go out of tune, possibly by accumulation of tarnish or rust, or maybe mechanical effects of being played hard. So when the valves have been fixed, the reeds may need tuning too, by scraping minute amounts of material from the base or tip of the reed, which is a skilled job.