By paying off small debts first you can reduce the amount of money you have to come up with each month. If you have any uncertainty around income or other expenses, there is real value in that.
Doubly so for debts that could be foreclosed on - if you prepay your mortgage a bunch and then fall behind and get foreclosed on, all that prepayment is just cash down the drain. If you had completely paid down some smaller debts instead, you would be in a better position.
Basically, paying down higher-interest debt first is optimal only if you're certain that you'll never default on anything.