The thing is its not supposed to be fought straight up. You're supposed to find some way to deal with it that doesnt involve face-to-face melee, which is sometimes tactics, more often brains or something enabled by brains. Narratives often feature critters like that. Smaug forinstance, as an obvious example. CR 7,894 dragon vs a CR 15 town, a lvl 20 ranger and a lvl 6 rogue. Or an unarmed Luke vs the rancor. X-wings vs the death star. Arnie vs the predator. And so on. And yet, narrative! The point being that the DM only rolls that d4 for deaths if you dont try to outsmart the situation.