Praise be to Allah.
The basic principle is that it is obligatory to divide his time between both, based on the principle of justice between co-wives.
But the custom in many countries is that when a woman gives birth, she stays with her mother for forty days or less, so that her mother can look after her, or her mother may come and look after her in her own house. In either case, he is not obliged to allocate some time to her, and she may agree to waive her right to a share of his time.
Shaykh ‘Abd al-Rahmaan ibn Naasir al-Sa’di (may Allaah have mercy on him) was asked: Is it obligatory to allocate a share of time to a wife who is menstruating or in nifaas?
The well known view in our madhhab (the madhhab of Imam Ahmad) is that he must allocate a share of time to each of them, because they are both wives. But the correct view which should be applied is that the menstruating wife has a right to a share of his time, but in the case of one who is in nifaas, she does not have a right to a share of his time according to custom and because the woman in this situation usually agrees to give up that right; in fact in most cases whilst a woman is still in nifaas she does not want a share of her husband’s time and this is a view in our madhhab. End quote.
Fataawa al-Mar’ah al-Muslimah (2/693).
And Allaah knows best.