Ristolainen’s numbers have been in the toilet for his entire career and it’s reasonable to conclude that Buffalo is bad because Ristolainen has been their #1D and not vice versa.
He's just not a first pairing player. It's like... regardless of how you feel about Brenden Dillon, for example, asking him to play 1st pair minutes is just over his head. When you look at his tools, there's not a lot about him that actively screams that he's a bad hockey player. When you watch him play, he's usually good for a handful of plays per night that make you say "I don't think that player's necessarily bad at the game". He's just not what Buffalo was forced to use him as (from a very young age).
You want to look at how that franchise is run top to bottom and say it's more because of Ristolainen than the team around him? That's a bad take.
For the record I think Ristolainen is better than Dillon, but it's the best Capitals equivalent of a defenseman that would cap out and could be forced to play way over his head, whose results may indicate that he's barely an NHL player, but with a new role would be fine.