India has always been an odd, exceptional case though. Years ago, both China and India complained that they shouldn't be lectured to by Western countries that enriched their own economies using fossil fuels. China though has changed perspectives, especially after gaining such an advantage in the solar industry.
India, however still struggles with their use of coal and fossil fuels and this is for a few reasons.
India, like China, with a billion population, has not been able to advance its economy or raise people out of poverty as fast as China has been able to, so India is still reluctant to be as committed as China has become in its ability to pull back on the use of fossil fuels.
Environmentalists in India, with help from citizens who are sick of dirty air (Delhi has some of the worst air pollution on earth, often surpassing Beijing's poor air quality in levels of particulate matter) pushed the government to make more of a commitment and India's government slowed the rate of building of coal-fired power plants but not nearly as much as China, which has actually closed plants.
In India, it's not so much about protecting the industry as it is about wanting to use the fastest means available to raise people out of poverty. Change takes time, effort and money.
And for all the talent that India has (it has probably the highest number of highly skilled tech workers), India has a very messy bureaucracy and infrastructure and for these reasons India's economy has lagged compared to China.