Must Minigiant explain how spells work?
D&D spellcasting runs on the "Language of the universe" aka True Names.
Anything you say in the Language just happens.
The problem is the Universe hates when you speak the language.
Only gods, beings with a divine portfolio, can say the language unfettered.
When Jane the Cleric prays to her god for the daylight, her god can say "Jane can cast daylight".
Now the entire universe warps around Jane and she can use spell slots to cast daylight.
Wizards don't have a god speaking True Names for them. They must say it themselves. Unfortunately they are mortal an can't.
So wizards get around it by speaking several bastardized dialects of True Names.
Hocus Pocus is a drunken cockney true names.
Somatic gestures is True name sign language.
And for some reason the universe associates fire with bat poo so you must display it.
The last method is to be magical. By having magic into, you can subsitute your body, bones, and blood for the words you can't say but must.
Because Luke the sorcerer's great grandpappy was a fire dragon, he doesn't have to speak the "5 times ran through Google" word for fire when casting fireball.