How to save a prefab when a button is pressed

In my scene I have a small character customization mechanic where the player can change the head, torso and color scheme of the robot character. However I want the changes to save so it can be loaded in other scenes and when the app is closed it loads up the same instance how do i do this.

As you can see the droid from the current run-time is different from the droid prefab in the project. How do I overwrite the project droid with the current instance when the save button is pressed.

You can create prefabs at runtime with the PrefabUtility.CreatePrefab function. Take a look at the ReplacePrefab options available as a parameter.