Airlines optimize allocation of planes on the basis of actual occupation/sales, which is particularly easy for short/medium haul if you have a range of planes like Airbus 318/19/20/21 or B737 types. Long haul this flexibility is usually less, but also there it happens once and a while.