I created an outline on a new layer over that part of the person from the complete photograph who is to be in front that will cover the person who is to be behind. png file that is the person extracted from another photograph: jpg file that is the complete photograph that will have a person added to it, and one. May I state what I have done so far, bearing in mind that I have one.
Sadly, in spite of my many hours trying, I have not been able to achieve the desired result. I am sure that your procedure is precisely what I need.