People ask for closeness to God and for help when they pray.
Some claim that God is not influenced by our prayers at all. For them, an answer to prayer does not mean the prayer influenced God but means that God had decided to grant the request before he was asked - if he was asked.
Some say that though God cannot be influenced, he knows what is best and right more than we do, he can let himself be influenced. Sorry that is incoherent.
Prayer is meaningless without the idea that God can intervene and change things to put them the way you want them. If you thought God would do these things anyway, you wouldn't see the need to ask for change. The more asking you do the more you would be acting like you are trying to force his hand. If you really trust someone you just ask them the once and if you need to. Prayer encourages egotistical thinking and desires.
You may pray, "God help me to submit to your will and accept whatever you choose to do." That is still a petition - asking God to change something.
Prayer is really a disguised and dishonest attempt at magic. It is you trying to be a God who is independent of any real God that could be out there. You want to feel as free as God by giving in to God. You want to get this feeling from him.
Prayer really suits paganism best for it is full of indecisive gods who need our guidance. It does not fit the notion of an all-powerful all-loving God.
APPENDIX
If God does not need our prayer then it is a waste of time. A good God would rather you spent your time helping people. Prayer is an insult.
Perhaps God just asks for prayer so that we will spend time with him in love and develop a relationship with him? But we can do that without getting down on our knees and praying. Obeying his commands to help others knowing that it pleases him should be the kind of prayer he asks for because it is striving harder to be his friend. Things like going to Mass and taking communion are wrong.
The Catholic Church insists that the saints intercede with God. So it cannot hold that prayer does not influence God for interceding means influencing. The saint might not get what he intercedes for but he has still exerted some influence.