MOSFET
If the MOSFET is partly on, it will reduce the power going through it. It does that by converting some power into heat. Even if it is on, it will still convert some power to heat. The MOSFET also has a resistance. When current flows from the MOSFET's drain to its source, there will be a voltage drop. Multiply that current, and the voltage, to get the power loss. That lost power becomes heat. The MOSFET must get rid of that heat, usually by passing it into the air. Smaller MOSFETs warm up and heat the nearby air, while some other MOSFETs must be on a circuit board, which has a larger area to heat more air. The highest-power MOSFETs must be under a heatsink.