If the target creature is an illegal target by the time Transmogrifying Wand’s ability tries to resolve, the ability doesn’t resolve. No player creates an Ox token.

Artwork
Loading artwork…
Transmogrifying Wand
Commander Masters · #981 · EN
Nonfoil—Foil—
Card rules
This artifact enters with three charge counters on it.
1,
, Remove a charge counter from this artifact: Destroy target creature. Its controller creates a 2/4 white Ox creature token. Activate only as a sorcery.
Rare · Illustrated by Aaron Miller
Format legality
Brawl Legal
Commander Legal
Competitive Brawl Legal
Duel Legal
Gladiator Legal
Historic Legal
Legacy Legal
Modern Legal
Oathbreaker Legal
Penny Legal
Pioneer Legal
Timeless Legal
Tlr Legal
Vintage Legal
Alchemy Not Legal
Future Not Legal
Old School Not Legal
Pauper Not Legal
Pauper Commander Not Legal
PreDH Not Legal
Premodern Not Legal
Standard Not Legal
Standard Brawl Not Legal
Rulings
Published rulings from the downloaded Scryfall catalog. Source card record · Rules and interactions
If the target creature is a legal target but can’t be destroyed, most likely because it has indestructible, its controller gets an Ox token and gets to keep that creature.