Here are your parts includes a wiring diagram.
Replacement parts for MAYTAG MDE2400AYW Dryer - Ele | AppliancePartsPros.com
Often if you click on the parts picture a new page will open with more views of the part. May be useful here.
I cross referenced your part number for the heater on this site and it does look like the correct one.
Here is a service manual which should come in handy
It looked fresh from the package. The wiring as well showed no signs of burning. The burning smell was throughout the dryer's interior.
I would check the new heater assembly with a meter.
Also check that it's coil is not grounded (touching the case). Disconnect it and measure all contacts to the case, all should be infinite ohms.
The location of the arcing/burning will not necessarily be at the heater itself.
Since you had arcing and a burning smell there should be some evidence of this. Could be weld marks, bubbled wire insulation, etc.
I would look at the unit's terminal strip first. Then you will have to work your way through the unit. Hopefully the control board will check OK.
If you do find a problem area be sure to clean/check this carefully.
That it heated here is an indication of a bad connection (resistance in the connection). As current flows through this connection it will heat up, which makes the connection worse, which causes more heat etc, etc, etc. until the connection fails in the future.