Isolation is a powerful weapon in the hands of those who are trying to control a society. It's the reason why, throughout history, evil forces have used imprisonment, scare tactics, book-burning, and a myriad of other measures to make sure that the people who could endanger the powerful are separated. The purpose is to make every last one of them feel alone and helpless, to keep the general population from thinking too much and from believing there's a chance for things to be different.
In the novel A Thousand Splendid Suns, that isolation runs deep within the Taliban rule. Men are not exempt from this, but women are put down the most. From the removal of individual rights to the oppressive clothing to the lack of opportunity, they are not just isolated from the world, but from each other as well. Systems like that aim to turn people into capsules of loneliness, hoping that their spirit shrivels. After all, when you're that put down, it's harder and harder to show empathy.
That is what initially happens to Miriam and, to a degree, Laila. From Miriam's point of view, she does not have much in her life at the time when Rasheed decides to marry Laila. She is stuck in an abusive, terrible marriage, but without the hope of having children of her own, it's the only thing that's really hers. A person without anything would protect even that which does not make them happy. So naturally, lost within that isolated world that women of Afghan face, she resents Laila—who becomes pregnant seemingly miraculously fast, as if fate is trying to spite her further.
To the reader, it's more or less immediately obvious that these two souls could benefit and help each other, but it's harder to see from inside the bubble the Taliban has built around them. Only as time passes do they realize that, piece by piece, the isolation shrinks away through their new-found friendship and the front they form against their husband.
Isolation in A Thousand Splendid Suns is portrayed as poison to a healthy society. With the example of just two people—Miriam and Laila—Hosseini shows what can be done when those who believe themselves to be powerless discover that they have strength after all. Separated, neither Miriam nor Laila had much success in standing up to the cruel Rasheed, but together they could fight for their freedom and happiness.