This is not true. Indian courts are very much functional and is not elected by politicians. So they are not as hamstrung as any US courts if you are going to start comparing. Only issue is the long delays involved.
All judicial appointments need to be approved by the government. Retired judges get plum political appointments including to the Rajya Sabha.
The Centre refused to appoint Saurabh Kirpal because he is openly gay. This isn't some wild conjecture, this is the official government position: https://www.barandbench.com/news/law-ministry-says-saurabh-k...