It might seem harmless, but the purpose of a joke is to draw a distinction between those who get it and those who don’t, fostering a sense of community. In this “joke”, the in-group is people who don’t know something; the community ideal fostered there is that knowledge is undesirable, that anything that seems unintuitive to the uninformed mind is inherently ridiculous. The “joke” has no effect if it doesn’t do this. Entertaining the idea without challenge is dangerous.
That’s where you’re wrong. The joke is based around a play on words: the generally accepted definition of imaginary, and a math term. Thus, the in-group for this joke are people familiar with the common definition of imaginary, and familiar with the fact that “imaginary numbers” is a term used by mathematicians. The joke being that, if they use the term “imaginary numbers”, then someone came up with numbers that don’t fundamentally exist, and they were only used to cheat out an answer to a difficult problem. Of course, in math this isn’t the case, the numbers most definitely exist. To me it just seems like you’re trying to be a pompous know-it-all and ruin people’s fun, but you can’t even do that correctly because you didn’t understand what the joke even was.