The Prophet ﷺ said, "None of you should say: 'O Allah! Forgive me if You wish,' or 'Bestow Your Mercy on me if You wish,' or 'Provide me with means of subsistence if You wish,' but he should be firm in his request, for Allah does what He will and nobody can force Him (to do anything). (Using translation from Bukhārī 7477)
وَقَالَ رَسُولُ اللهِ ﷺ لَا يَقُلْ أَحَدُكُمْ اللهُمَّ اغْفِرْ لِي إِنْ شِئْتَ وَارْحَمْنِي إِنْ شِئْتَ وَارْزُقْنِي لِيَعْزِمْ مَسْأَلَتَهَ إِنَّهُ يَفْعَلُ مَا يَشَاءُ لَا مُكْرِهَ لَهُ