It's like this.
Words have power.
The words uttered by wizards have great power.
The more forcefully spoken the words, by the most senior Wizard, the more power they have. And in a time where a vast amount of surplus life-energy is slopping around (ie, the interregnum period between Deaths which is described in Reaper Man), they took on most power of all and popped into discrete incarnation.
Mustrum Ridcully, an Archchancellor whose everyday language might well be described as salty, learns this to his cost as a range of insectoid creatures begin to unaccountably, and at first un-noticed by the Wizards, pop into physical existence. These range from the fairly innocuous Lesser Blasted ("a tiny purple spider-like creature") through the Bugger ("a slightly different variety of mad waspy creature"), to the Imperative "Emperor" Blasted ("a long creature with four pairs of wings, two at each end, and three eyes"). There is also the Passing Damn ("a large bluebottle with cat-sized dentures") and the mercifully undescribed Bloody Hellfire!.
Just as a newly-hatched duck will imprint on the first thing it sees and regard it as Mummy, the swear-words, once called into existence, orbit in a swarm behind Ridcully in the hope of further sustenance.
Ridcully also generates two creatures which, in the entomology of Swear-Words, must be the equivalent of those eight-inch African stag beetles. While the precise combination of language that calls them into being is left to the reader's imagination, save that it possibly requires a robust country upbringing full of experience and an open mind, these two prime specimens are respectively:-
Something small and striped red and yellow, with tiny dripping fangs and making a sound like a miniature buzz-saw
It was fat, round, black and glossy, with horrible eyebrows, and capable of blowing insectile raspberries.
When this latter creature and its attendant train of Hells and Damns and Blasteds pops into existence, the penny finally drops that a new spell, possibly called "Ridcully's Entomological Generator", has been called into existence. Such a spell would effortlessly combine entomology - the study of insects - with etymology - the study of the origins of words. The other wizards persuade Ridcully to moderate his language, and he subsides into a gloomy half-hearted series of Poots, Darns and Drats which do not relieve his feelings one little bit. This culminates in the most genteel battle-cry ever formulated: "Darn Them to Heck!"
Logically, the Swear-Words should have dwindled and faded out of existence when Death re-asserted Himself at the end of Reaper Man, and the leakage of surplus life-force ended. But since when has mere logic had the final say on the Disc? As the Swear-Words were born into a magical University, it is likely that they are now an established part of its ecology and have found other ways of sustaining themselves. Perhaps a Professor of Un-Natural Entymology is categorising them even now?
In similar circumstances, witches have known this for years and are far more careful with the more, er, serious, sorts of swear words on the lips of a practitioner of magic, as they don't know what they could turn into. In The Sea and The Little Fishes, Nanny Ogg's immoderate use of language in a time of stress during a high summer full of life energy causes minor grass fires to erupt, everywhere a cuss-word comes to earth.