No, he's not at Madrid or Barcelona because they actually want their midfielders to be well rounded. Dembele is not great defensively, and offers nothing in attack with no creativity and no goal threat.
He is good at 2 things, holding onto the ball, and transitioning defence into attack. The problem with that is every top team has players who can do that and other stuff.
This is why Dembelé only works in a system where his defending is done by Wanyama and the 3 CB's behind him, and his attacking is done by Eriksen and Alli ahead of him. He's the ultimate luxury player, and his reputation has been blown up an insane amount by a couple of good performances in games where being this extra man has worked out well tactically. He then goes months out of form or playing badly when Spurs need more from him.
There's a reason they'll reportedly happily let him leave.