What is a tuck?
The downhill tuck is a position/posture/pose that maximizes straight-line stability and aerodynamics, so you can go fast in a straight line.
Aerodynamics:
You get both your knees in line, hide your arms behind you, and attempt to close the gap between your chest and front knee. This may not seem like a lot, but at speed, aerodynamics matters much more than at cruising speeds.
Stability:
You press the rear knee into the lead calf, deweighting your back leg to add weight into the front truck, which aids in stability. This position can also do some turning, called tuck leaning, but for any hard turns or slides, you will need to untuck
When to tuck?
You should tuck if you're going fast and want to go faster. Think of it as your gas pedal once you're beyond pushing speed.
Downhill skating starts with a select amount of energy (how hard you can push + how tall the hill is) and you need to maximally convert this into speed by decreasing the factors that bleed off your energy (aerodynamics/drag, poor lines, and to a much lesser extent, bearings). The biggest 2 that a rider can control are clean lines and aerodynamics. Tucking maximizes aero.
When to untuck?
You're about to corner
Certain sharper corners require riders to untuck to get into the turning posture for heel or toeside
You want to airbrake, footbrake, or slide
Pretty obvious, but you have to untuck to footbrake and slide. You can airbrake by raising your chest with your knees still in tuck and spreading out your arms. Additionally, euro footbraking can be done relatively easily, but you still have to untuck.