Answer: I have 3 answers you could use.
Glowworms aren't actually worms they are beetles. They use their bioluminescent bodies to communicate with other beetles, in an attempt to attract a mate.
Or
Glowworms are not actually worms, but the larvae of fungus gnats, an insect that looks like a mosquito. There are two types of fungus gnats – those that feed on fungi like mushrooms, and those that are carnivorous and feed on other smaller insects.
Or
The glow-worm is a medium-sized, narrow beetle. The males look like typical beetles, but the females have no wings and look similar to the larvae. Glow-worms are most often found as larvae, living under rocks on chalk or limestone grassland, and feeding on slugs and snails.
Explanation: Hope this helps <33.