Actually there are two reason, first is rising labour cost in china & second one is geo political risk involving Chinese supply chain, that's why many American & european companies wants are following china +1 strategy, so they're creating an alternative supply chain which is not dependent on china since Apple is an American companies so obviously they Knows the risk involved with china supply chain and it's not just india. Apple is moving part of their manufacturing to Vietnam too and other companies or contract makers are also moving out of china.
Also people don't buy apple because it's made in india or china, people trust in apple brand and Apple is one of the companies who cares about quality of it's suppliers and they do alot of inspection.
China now have to deal with reality and creates it's own brand as good as apple or even high end of samsung products.