Because the general public finds a man in a dress funny. Especially if they look bad in it. The writers don't know anything about crossdressing or drag beyond what they've seen on other shows, or the badly presented transperson they might have run into sometime. It's a self-replicating bias...
And minorities are always being shown as stereotypes in the worst light. The majority always uses the minority as the butt of their jokes-because it's easy.