They do. The Chinese government gave them a special exemption, presumably because they wanted to build EV manufacturing expertise. Other foreign auto companies are not allowed to open their own factories in China; they have to do a joint venture with a local manufacturer.
BYD has been making batteries since '95, cars since '05, plug-in hybrids since '08 and EVs since '09. I don't doubt that China may have made use of Musk, but I severely doubt he's the one who "taught them how to build an EV".
If you think China can only make stuff by copying what other does, you're gonna under-estimate them.
The timing doesn't line up. BYD has already been selling EVs by the time Tesla opened a factory in China. Heck, they were selling EVs even before _Tesla_ existed.
And they clearly have their own expertise. There are videos of BYD and Tesla car teardowns, and you can see that they quite differ in design philosophies.
I think China was more interested in creating more competition internally, rather than just ripping off the technology.
It's not. China has literally _thousands_ of years of bureaucratic institutional memory. And it just keeps perpetuating itself.
Before the 20-th century, the Chinese officials had to study the classic Chinese literature and pass exams based on that knowledge. These works were completely abstract and literally useless in day-to-day work. And you had to follow all the rituals to demonstrate your allegiance and being-in-the-group.
Now they just swapped the Classical Chinese works with Marxist writings. Nobody cares about their content, but you have to know them and you have to follow the rituals.