Mountain biking takes a special blend of strength, endurance, balance, and coordination, all of which can all be improved with targeted training before you hit the trails. And you can never start training too early. Your body needs time to adapt, build strength, and improve the resilience of your muscles, tendons, and ligaments.
XC riders your focus should be on your aerobic fitness and increasing core strength.
DH riders, alongside core strength, you should work on your overall strength, grip, and upper body stability.
For riders and people in general tbh knees, shoulders, and wrists are common weak points. Targeting the muscles around these joints with strength training is one of the best ways to reduce injury risk.