He received huge amount of subsidies. For example Tesla car buyers received, if I remember correctly around 9000 USD in tax refunds for buying Tesla cars in the US. Situation in some other countries like Norway was similar.
Other car manufacturers have to buy carbon credits from Tesla to average down the carbon emission per car that they sell. With the solar panels- electric utilities MUST buy excess electricity from households that install solar panels at retail price which mean they are losing money doing it, so they have to increase the electricity bill for everyone else. There are numerous other ways that Elon Musk's businesses siphon money directly from the tax payer rather than from legitimate customers.
I know about this energy issue.
People who produce Solar and Wind Energie get higher prices for their energy, than the market price.
Their energy must be bought by the big energy companies first and with a fixed from the gouvernment determined price.
Later this energy is mixed with classical produced Energy that is usually cheaper.
The customer has now to pay a higher price and the producers of "alternative" forms of Energy earn.
But there are serious problems with this modell.
0. The rich people invest in this and have additional gouvernment garanteed income, while the workers and employees have every year higher energy costs. You pay for a small family every month already 200 to 300 €! So basically it hurts equality!
1. Sun is not always shining and wind not always blowing.
2. In the energy net must put always the same "ammount" of energy that is consumed. Otherwise blackout!
3.After the banning of atomic energy and coal energy, there is a problem to keep enough classic energy production capacity in storage. So i.e. in Germany they build Gas Energy Plants.
4. Russia is the only country that is able to deliver the ammounts of gas with a good price. USA can make a good price too, but the transport and liquifaction is expensive.
5. The prices of energy are already very high. So Germany is forced to buy the gas from Russia and feed the beast, while asking for US protection from the beast. The 2% of the BIP for defense is not possible, because Merkel has spent everything on her projects Euro rescue, refugees and pension reform and is not able to raise the energy prices otherwise she risks unrest. So the tensions between US and Ferkel are serious.
But all this has nothing to do with Musk. If you compare the electric cars from Audi, BMW and VW with the Tesla, they are a bad joke! I repeat it, they are very expensive and you are not even able to visit with them your relatives without long loading breaks. Tesla has produced the only usable electric cars in the market. Subsidies are getting all companies the same. But the German cars i.e. are not selling because they are very bad.