It's shameful that the UK imprisons political figures for no UK crimes in solitary confinement indefinitely.
Really?
He was facing prosecution from a European country, they asked for him to be extradited to face his accusers in court, in a completely normal manner (although it is worth noting he appears to have run from that country as soon as he realised there was an allegation, before he could be questioned).
He fought the extradition as was his right.
When he failed to fight it because he couldn't show any legal reason it shouldn't go ahead he went and voluntarily put himself in solitary at the embassy for a third country (where he was, by all accounts an utter idiot), and thus breaching the conditions of his bail conditions in the UK.
By breaching his UK bail conditions with his attempt to evade the legal system he committed a major offence against the UK legal system, in much the same way that lying to the court about who was driving your car when it was found to be speeding can move you from a minor offence that no one really bats an eye at and only cost £70 and a couple of points on your licence into a potential jail sentence and a history that will see you screwed for any loans/many jobs.
So once he finally decided to stop hiding in the embassy/they kicked him out the courts in the UK were never going to let him walk the streets (and attempt to run again) whilst they had another extradition request because he had already shown he wouldn't honour any bail conditions.
So now he's in jail for the full time whilst he fights facing a US court.
Of course the funny bit about this is that if he hadn't messed about with the original extradition he would have been sent over to Sweden, a country whose prisons are basically much nicer than anything found in the UK, let alone the US, and a country that IIRC is far harder to be extradited to the US from, and if he'd cleared his name there he could then have potentially claimed asylum or simply applied to stay in the country.
Basically he chose to spend years in a small. reasonably room, without the ability to go outside and that backfired by leaving him much more vulnerable to not having a choice about being stuck in a small uncomfortable room.
The TLDR
He was an idiot who thought the law shouldn't apply to him and made it so the law had zero choice but to lock him up during the entirety of any remaining legal challenge once they got hold of him.