Either explain it or don’t.
When authors include things that don’t fit within the real world–magic, time travel, anachronisms–there is an impulse to explain how it works. Which can be fantastic for worldbuilding, but if you don’t know what you’re talking about, it can make more problems than it solves.
Stephenie Meyer tried to explain some bizarre thing about chromosomes, and it made the biology of vampires and werewolves make no sense. Suspending disbelief worked better in that case before she tried to ground it in the real world.
Lemony Snicket, on the other hand, just has random anachronisms that are never explained, but because there’s nothing even close to resembling an attempt at an explanation, we can just shrug and go, okay, that’s how it works. The magic in Harry Potter seems to basically not be grounded in anything, but we can believe it within the context of the story because she doesn’t try to ground it in anything.
In Jim Butcher’s Codex Alera, on the other hand, he goes into a lot of magic theory, and it gives us a strong feeling of worldbuilding. There’s enough logically coherent explanation for it to feel grounded within itself.
It is possible to go too far (see: Orson Scott Card’s Xenocide and Children of the Mind) where the plot ends up so tied in the reader understanding intricately detailed scientific and pseudo-scientific minutiae that the story is incomprehensible without it.
Generally, though, if you’re going to make something up, either say it exists and leave it at that, or entirely figure out how it works. Halfway is always less believable than nothing at all.