No, it isn’t happening because God is mad at you (even if your wife is). God doesn’t want your marriage to be destroyed, and you shouldn’t blame Him for whatever has gone wrong. God gave marriage to us, and His desire for us is clear: “What God has joined together, let no one separate” (Matthew 19:6).
I realize it may be too late for your marriage to be saved, but even if it is, God still loves you, and He wants to teach you through this experience. This is why one of the most important things you can do is to ask God to help you discover what went wrong, and why. It’s easy to blame the other person (or even God), but what could you have done differently? Were you selfish or insensitive? Were you demanding or controlling?
Whatever your answers, face them honestly and humbly, and then ask God to help you change and become the person He wants you to be. The first step is to turn to Jesus Christ and ask Him to come into your life. You need His forgiveness, and you also need His help to become the kind of person He created you to be.
Ask God to help you look forward and not just backward. In other words, don’t be bound by feelings of anger, failure, rejection, or anything else. Instead, commit your future to Christ and make it your goal to follow Him every day.