It'll attack you, it'll run out of reach and spawn its young, which need to be defeated. You need to make use of your slingshot. There are other bosses in the series that do less and dont look as impressive.
I don't remember the boss name, or even which game it was in ... but there was another boss that did similar things to Gohma ... but this one was more like some kind of fish-frog that had eggs all over it's back, would shake them off, and then you'd be ambushed by tons of baby fish-frog-tadpole things. Not saying it's THE same thing as Gohma, but it was similar.
Sounds like the mini boss in lakebed temple in Twilight Princess.
I love that miniboss.I just looked it up, and you're right. It's the Deku Toad I was thinking of. Not a full-fledged boss, but still similar in concept to Gohma.