I suspect most of the time "old" guns are the result of stockpiling, either at the factory or the distributor, or both. Most gun factories do not make all the lines all the time, they simply are not big enough. So they will tool up for the Model X, turn out however many they think will be needed until the next cycle, then break the line down and tool up for the Model Y and so on. If things work right, the stock room will run out of Model X's just as the line begins turning them out again.
But if the cycle is disrupted, say the Model X proves very popular so management decides to extend that model's production time, things can go wrong. Conversely, guns are not like bananas. They don't go bad in storage, so if some Model X's are still in the stockroom when new ones come off the line, the new ones go on top of the pile, and the older ones can remain on the bottom for another cycle or two. The same can happen at the distributors or even at a large store or chain.
That is part of the reason why companies don't like to publish serial number/date of manufacture data. Some folks don't want an "old" gun, even though it is absolutely identical to a "new" gun.