It depends on several factors such as the map, team composition, and to a lesser extent team skill. I've been Zarya as the lone tank on Anubis on a few occassions where the enemy team didn't even make it through the main archway. All you need is a half-decent healer and some people to help harrass the frontlines and get your charge up.
You can't really make blanket statements like that. That's what makes this game's meta (non-competetive at least) so varied and entertaining. I like to play D.Va on attack if no one else has gone tank. She can do serious work on payload maps, especially Route 66.
Just because something works a few occasions doesn't mean it's actually good. I've won games with all offensive characters. Hell, I won ranked games like that. That doesn't mean it's a good strategy at all. I am not saying zarya solo defense tank never works, but that it's not good to work enough. Anything can work. I've won games, even in ranked, with absurdly bad team compositions. The fact that something works every once in a while just doesn't justify it.
Zarya suffers perhaps the most from a death and on defense that means you're at the sufferance of an attack without a tank for a good 20 seconds. And regardless of whether you walk back, teleport, or get a revive, you're starting at 0 charge again. Reinhardt can charge back, winston can hop back, even d.va can fly back. And roadhog often has an element of surprise when he hits the field again, and at least starts at full strength.
You can't just look at it from the perspective of just completely out killing, out damaging and pure out skilling an opponent team who refuses to adapt. You should try to gain meaningful advantages against your opponent through your composition, to maximize your chances of victory. Because after all, you can win with a 6 man hanzo team. But when you do it's because your opponent team was completely outskilled and clueless on how to play the game.