Mean-field theory of graph neural networks in graph partitioning