Can a phone be unlocked when a activation code is sent by using phone password?
When a phone is erased? And someone sends a activation code? Can they unlock it if they have the phone passcode?
iPhone 7 Plus, 15
When a phone is erased? And someone sends a activation code? Can they unlock it if they have the phone passcode?
iPhone 7 Plus, 15
If you are the owner or the owner has shared all information with you then to open Activation Lock:- If it is Activation locked, read here --> Turn off Activation Lock - Apple Support Activation Lock for iPhone, iPad, and iPod touch - Apple Support
Learn how to remove a device from a previous owner's account.
If you are not the owner and do not have the Apple ID and Password then there is no way that you can get into this iPhone unless the original owner shares the Apple ID and password with you. If you are lucky you can get into this iPhone if they (owner) accidentally remove the device from their Apple ID.

If you are the owner or the owner has shared all information with you then to open Activation Lock:- If it is Activation locked, read here --> Turn off Activation Lock - Apple Support Activation Lock for iPhone, iPad, and iPod touch - Apple Support
Learn how to remove a device from a previous owner's account.
If you are not the owner and do not have the Apple ID and Password then there is no way that you can get into this iPhone unless the original owner shares the Apple ID and password with you. If you are lucky you can get into this iPhone if they (owner) accidentally remove the device from their Apple ID.

If the device is removed from an account after it is erased, Activation Lock will be turned off. This allows another person to turn on and use the device.
An example of my iPhone 5 is given in the GIF below. There is no "Undo" after you remove it from your account.
The link on top of this page which you had visited, before posting this question here, is shown under the "Related Article” that may have given you an answer.
You need to mention which part of the article was not clear to you.

Can a phone be unlocked when a activation code is sent by using phone password?