If you don't have this problem while the assembly is still loose, my best guess is that you have an unwanted contact somewhere, causing a short circuit or malfunction. Perhaps in the bending of the flex?
Hi, does your replacement screen have the home button assembly included? Otherwise there's need of soldering the assembly to it before it can be installed.
I suppose the foam adhesive is similar to the one on the back of the 6s screens. I guess it has more of a heat dissipation function or is meant to absorb any pointy pressure points from inside that may develop (loose screw, sand, dirt...)