The Quran regulates the matters of divorce so that it isnt approached lightly, not caused by transient emotional factors
65:1,4:19"If you take a dislike to them it may be that you dislike a thing and Allah brings about through it a great deal of good".
It bans the pre-islamic practice of dhihar/zihar where husbands would arbitrarily physically repudiate their wives, considering them as unlawful as would be their biological mothers 33:4,58:1-4. Such injustice must be compensated through repentance and atonement; charity, fasting or the freeing of a captive. If not, then the wife remains unlawful to the husband, opening the way for her to seek divorce due to the husband not completing his matrimonial rights.
It is to be noted, the disapproval of that practice was mentioned in surah ahzaab much prior to sura mujaadila, where the options for atonement are given. We read in the traditions of a woman who complained to the prophet that her husband had declared zihar on her. Knowing that the Quran severely disapproved it, the woman, despite the prophet's advise to return to her husband and resume her marital life, sought for a way, on behalf of her husband to regain God's approval. The prophet's advise was due to the man's old age, described in some reports as becoming mentally confused as to his statements. Further, the Quran considers zihar a falsehood that has no bearing on the validity of the marriage. In pre-islamic days, the statement of zihar amounted to divorce. The verses 58:1-4 were then revealed, reiterating the negativity of the practice and opening a way for repentance. Khawlah desired to return to her husband, even pleading for him, but due to her piety, wanted to do so with God's blessing, and God honoured her attitude forever through the revelation of these verses
"My husband, Aws ibn as-Samit, pronounced the words: You are like my mother. So I came to the Messenger of Allah, complaining to him about my husband. The Messenger of Allah disputed with me and said: Remain dutiful to Allah; he is your cousin. I continued (complaining) until the Qur'anic verse came down..I said: I shall help him with another date-basked ('araq). He said: You have done well. Go and feed sixty poor people on his behalf, and return to your cousin. The narrator said: An araq holds sixty sa's of dates. Abu Dawud said: She atoned on his behalf without seeking his permission".
The traditions report that her status among the companions was such that they would stop and listen to whatever she had to say, bowing their heads in humility, calling her "the one whose complaint was heard at the seventh heaven".
The divorce matter is neither wholly in the husband's nor the wife's hands. A judge designates two arbiters, one belonging to the wife's family and the other to the husband's 4:35. The arbiters' primary objective is to effect a reconciliation during a counselling period of three months -called idda- where the husband remains financially responsible for his wife 65:1,6. He may not drive her out of the house by force and neither should she leave in anger 65:1, the underlying idea being that advantage may be taken if there is any chance of reconciliation unless, she has clearly committed an indecency or if they mutually decide to separate then she has the right to a decent lodging place 65:6, nor can he retain her injuriously 2:231. That temporary separation may cause conjugal relations to be re-established
2:228"and their husbands have a better right to take them back in the meanwhile if they wish for reconciliation; and they have rights similar to those against them in a just manner".
This is the best safeguard against a misuse of divorce, for in this way only such unions would be ended by divorce as really deserve to be ended, being devoid of the faintest spark of love. Their husbands have more right to them than another proposer 2:228, and this right can be utilized by taking them back in case he has initiated the procedure and revoking the divorce during the period of waiting
65:2"So when they have reached their prescribed time, then retain them with kindness".
However if all hopes of reconciliation fail, a divorce is pronounced and by no means is it viewed as a taint, rather the start of a new page with better opportunities
4:130"if they (should) separate, Allah will enrich each out of His abundance, and Allah is All-Embracing, the Wise".
The wife gets to keep her dower, a command preceded by an injunction to
65:2,2:229"let them go with kindness".
Whatever she has earned during marriage through business activities, she may keep it to herself 4:32 while the husband, even after the divorce is obliged to provide sustenance to his former wife in case she is nursing or is pregnant with his child until she delivers, according to his means 65:6-7. However in an exceptional case it is lawful for him to take back some gifts: when both parties desire legal separation, but the husband desists from divorce because he believes his financial loss, through wealth, assets or property, would be too significant. In such a case, it would be acceptable for the wife to return the gifts to her husband and for the husband to accept them
2:229"it is not lawful for you to take any part of what you have given them, unless both fear that they cannot keep within the limits of Allah; then if you fear that they cannot keep within the limits of Allah, there is no blame on them for what she gives up to become free thereby".
The Quran further prevents marrying them to someone else so as to take back their dower 4:32. The mahr/dower, once marriage has been consummated, is the wife's property. It cannot be taken by her husband unless she is proven guilty of immoral conduct 4:19, or if she knows that she will not honor her marital agreements, without any wrongdoing on the husband's part, thereby deciding to end the marriage 2:229,4:4. In the reverse case, the husband has no right to take back even a fraction of that dower 4:20. It is inconceivable he should take it back after being intimate with her, it would amount to a great sin from him, and humiliation to the wife. Although none can be forced to remain in a marriage one dislikes, even if it is for purely physical reasons as is the case here, the Quran again tries protecting the woman's dignity by discouraging the separation
4:19"live with them in a proper manner; then if you hate them, it may be that you dislike a thing while Allah has placed abundant good in it".
The Quran then demands mutual understanding regarding the child's future
65:6"take mutual counsel together, according to what is just and reasonable"
and if they disagree in the matter then it will be returned to the judge's decision 4:35.
A divorce may also be pronounced instantly without the 3 months iddah period necessary for counselling and to ascertain the wife's pregnancy, and that is when there was no sexual contact 33:49.
Men are particularly reminded in 2:229,2:230 that they cannot abuse of their right to divorce, neglecting the wife's feelings in the process. If he asks to divorce the same wife twice then he may not ask her hand a third time unless she has married another man and he has divorced her. Even if she feels the need to go back to that same man, he remains forbidden to her until she has experienced marriage with another man (muhallil). This not only deters emotionally abusive men, but it serves as an eye opener to women who might be tempted out of fear and psychological control, to keep on pardoning and returning to their abusive relationship. It opens the way to these abused women to go into society free of any blame, and start a new life with another man.
We find something similar in the HB in Deut24 where a divorced woman that remarries then divorces a second time, becomes forbidden to the man she was first married to. This is speaking of repeated sinfulness and sexual misbehaviour short of adultery. It is different that the problem the Quran addresses, as well as the solution it proposes. It would be of course inappropriate for a man to remarry a woman he had himself divorced for her immoral behavior. Especially if the second husband divorces her for the same reason, showing an established pattern of behavior. It would be an acceptance of sinfulness within one's household. The Quran equally forbids the righteous from marrying a sexually immoral person, until that person repents and mends his/her ways 24:1-25. There are no deadlocks in Islam.
Further reading answering Sam Shamoun "Who Really Follows Jesus? Muslims and the Issue of Swine"