Those "evil" mushrooms are known as "goomba".
According to TechInsider, these goombas are clearly chestnuts, not mushrooms. Mario creator Shigeru Miyamoto told video game website Eurogamer that 'chestnut' in Japanese is 'Kuri, this is where the name 'Kuriboh,' which is 'goomba' in Japanese, came about.
So, why the word for chestnut when goombas are "evil mushrooms?" One hilariously simple reason: "The original drawing I had was a black mushroom. And so a programmer started saying, 'It's a chestnut, it's a chestnut.'"
Apparently Miyamoto's drawing wasn't clear enough, or the programmer in question had never seen a black mushroom before. Either way, "kuri" — the Japanese word for "chestnut" — quickly turned into "kuriboh," a Japanese affectation of the word for "chestnut."
Find 8 'Super Mario Bros.' Tips, Tricks, and Glitches featured at Mental Floss.