Because panicking when you're being rag-dolled by even smallish waves can kill you, let alone waves of consequence. I don't have the words to describe what it feels like to be pushed to the bottom of the ocean by a wave, then just as you feel like you're running out of air be pushed back down by the next wave, and the next wave. You have no idea which direction is up and which is down, or how long it's been since you stopped breathing. 30 seconds will feel like death if you're not properly trained. Your very large very stiff board will be tumbling with you and could knock you unconscious or split your head open at any time.
My girlfriend got to be a decent surfer (~5 years practice and a former competitive swimmer) but never invested in learning the ocean. In 2018 she went out in a break she didn't know, in conditions above her league. Nothing too big (maybe 5 feet) but strong and relentless. Conclusion: She got sucked into the washing machine during a set and nearly drowned. Had to have the water beaten out of her lungs to restart breathing. Now she has panic attacks just getting into a flat ocean for a swim.
The sea is no joke. I encourage everyone to try surfing, it's a great hobby. But less than 10% of it is riding waves.