Sounds to me like this is what T-Mobile heard:
"I'm going on holiday, if I take my phone to Germany will it work?"
Answer: Yes.
And this is what you meant:
"I'm going to Germany, I want to put a German SIM card in".
Answer: If you are planning on staying there, or even if you just need the phone unlocking (it's a different network at the end of day just like Orange, O2) then they're either asking you to pay an unlocking fee or a contract termination fee.
If i'm right then T-Mobile have done nothing wrong. They might have assumed something they shouldn't have, but you should have known that trying to use a different network SIM card in your phone will not work.