adding car parts to car and removing them

hi i have a question, how do i make a system like in the game Street Legal Racing Redline? I want to know how can i store car parts in an inventory system and when i click on the part it would attach to the car and also the other way around if i click on the part on the car it gets removed and goes in the inventory