Which extension did you tried to obtain? You can't get 30 days extension. However, if you vring your wife with you, you can get the 60 days visiting Thai family extension once per visa.
That's the same all over the world. Doesn't make these senseless laws right though. A person has zero say where he was born, where he wants to live and work. No one can choose. All that those immigration officers around the world tells you is "go home!" What if I don't have home and doesn't feel belong.