To get an electric to sustain, you need to keep the energy in the string. The more the neck and body vibrate, the more energy leaves the string and the quicker your sound decays.
The concept of impedance matching applies here...but it's mechanical impedance, not electrical. If your string impedance matches your neck/body impedance, you'll have poor sustain. Necks and bodys always have higher mechanical impedance than strings, so you want this to be as high as possible for best sustain.
And what is mechanical impedance? It's a combination of mass and stiffness. You could create an "index of sustain potential" by multiplying the density of a material by its stiffness.
Of all the body woods Warmouth usually has in stock, the one that would rate the highest for sustain would be wenge. If they have a suitable piece in stock, Warmouth will make you a solid wenge body as a custom order.
Of the two, the neck is more important for sustain than the body. Same thing applies...weight and stiffness.