How to destroy a component created in scripts using AddComponent() ?

So, I have a code with two scripts, each of them having a class in it. Lets say a scripts called Car.cs and another one called MainCode.cs.
By habit, I also create 2 Gameobjects Car and MainCode containing the corresponding scripts as component.

My original plan was to create an Car object in MainCode , so I wrote : Car cr = new Car(); .

I get a warning telling me that I cannot do that and I have to use the AddComponent method. Ok, I do that and now, in my main code, I have :

Car cr = gameobject.AddComponent<Car>() as Car 

Everything works perfectly except for one thing. Each time I test my code, a new component Car is created in my MainCode gameobject.
It is what I want, HOWEVER, this Car component REMAINS in my MainCode prefabs, add each time I test my code, a new component is created and remains in the prefab. So I now have 20 components called Car in my MainCode prefab.

I thought the Garbage Collector was supposed to destroy those Component created in the scripts ?

Also, I tried to use Destroy(cr); but it I receive an error: Destroying assets is not permitted to avoid data loss.

What am I missing ?

if (GetComponent() == null) {
Car cr = gameobject.AddComponent() as Car;

Sorry, for not replying. Yes it did work. Thank you for helping !