Your friend should cease attempts to contact the suggested minor. His attempts to "fix" things are digging him deeper. He should not take legal advice from porn sites. He can very much get in trouble for child porn if the subject is under 18 no matter what age they claim to be. He should remove all such material and stop communicating with the suspented minors, leaving meetup if it has to come to that.
If he is contacted by the police or prosecutor or anybody else about the issue, he should immediately get to an attorney.

