Master-detail relationship options
When you create a Master-detail field on an object, you can choose Allow Reparenting Option.
Allow Reparenting Option
By default, records in master-detail relationships cannot be reparented. However, you can allow child records in a master-detail relationship to be reparented to a different parent by selecting Allow Reparenting Option in the master-detail relationship definition.