I would advise not to do this. A few hints:
- You can't get parts from Tesla if you don't own a Tesla. You can't get new parts from anywhere else. Your damaged car is not yours according to Tesla. You will have to resort to eBay and hope you can find the parts there. As there are lots of revisions done over the years getting the correct part could be difficult.
- If the car is officially totaled/scrapped you might have lost Supercharger access and possibly the onboard SIM is cancelled.
- The car also will no longer receive software updates from Tesla.
- Tesla will not service the car
- You cannot use the App
If you want to restore all this you need Tesla to re-certify the car. This costs approx $4000 USD (according to Rich Rebuilds).
These are all points that you will not see with any other car. If you would repair eg. a damaged Audi any dealer will be more than happy to shake all the money you have out of your pockets. They will happily fix and service anything as long as you pay for it. Tesla will say no thanks.
An Audi does not have an onboard SIM, does not have Superchargers and has no App. You can get parts from literally everywhere, etc, etc.
As Rich Rebuilds has also mentioned: Tesla scrap cars are going over the counter for absurd prices and are most often not worth the money you paid for it. Now I don't know if this is only true for the US or for Europe also, but some of the parts are in big demand, especially the battery pack.
Considering the time and effort and the uncertainty of the repairs I think it is better to buy a good second hand vehicle.
Now to answer your question, in The Netherlands we have sites for buying totalled cars, such as:
"sloopautos" means something like "wrecked car; for parts only"
Tesla sloopauto - Broekhuis
Tesla Sloopauto's overzicht
The UK also seems to have similar sites:
https://www.copart.co.uk/lot/21597427
Please also see:
P100D Salvage in England
Especially the user posting: "My friend with the Model S returned from the local Tesla parts dept having been told they will no longer deal with him - he's been buying small mechanical parts for weeks but it seems the 'Salvage Ban' has caught up with him !". Tesla really does _not_ want you to do this. Now regardless is that is fair or not (I think it is not), it is a fact as of today.