The issue at play here is not the prayer itself, but praying as a coach who is actively serving in his duty as the mentor/leader of the children of that assigned public school. His actions as a leader can and will be, representative of the school district and in this case serving as an endorsement of a religion which is a violation of the educator code of conduct (at least in Ohio). I've not read the entirety of the opinion, but I believe they ruled in favor of the coach as it pertains to his termination as a result of his religious belief. That would be the only justification in which the first amendment could and would apply to this situation.
For those comparing this to kneeling, you're correct that the actions are similar in that his position as a leader directly and indirectly influences the youth under his supervision. The distinction however, is that the act of protesting is protected and promoting faith as a public employee is not. I think this situation is different than some of the others that have come up, but my fear is that these "optional" prayers will become more prominent and ultimately we all know how "optional" things work in sports.
I struggle with this as a Catholic parent, not because another man is talking about god and praying. My issue is that prayer is taught to be a private conversation with god, and this bastardizes the importance of prayer in my opinion. I also think it is inconsiderate for me to expect others to view societal norms and what is appropriate based upon my beliefs and vice versa. However, I expect leaders i.e. coaches to be role models for our youth, and indirect or direct religious influence is not his or her responsibility. That responsibility is the job of the parent(s) and while we can agree that not every parent is active in this way, it isn't your right or job to fix those things.