A prison does not only lock its inmates inside, it keeps all others out. Her strongest prison is of her own construction.
In this first quotation, Dr. Jordan realizes that Grace is withholding information. He says that Grace has, metaphorically, created her own prison, which keeps him out but which also keeps her in. Ironically, however, it is this mental prison of Grace's own construction, which protects her. It is one of the few ways in which she can claim her own inviolate space, into which the various male authority figures in her life can not intrude.
I was there in the box of the dock but I might as well have been made of clot, and stuffed, with a china head; and I was shut up inside that doll of myself, and my true voice could not get out.
In this second quotation, Grace is describing her trial. She says that she feels metaphorically, "shut up inside that doll of myself" so that her "true voice (can) not get out." In other words, she feels constrained by the rigid social perceptions of her. Her guilt is predetermined and whatever voice others hear is only the voice that they want to hear and insist on hearing. Grace's true voice is muffled behind the "doll," which is a metaphor for the artificial, dehumanizing female construct that is, in the story, imposed upon all women.
When you are in the middle of a story it isn’t a story at all, but only a confusion; a dark roaring, a blindness, a wreckage of shattered glass and splintered wood.
In this third quotation, Atwood implies that a story is a linear narrative that we retrospectively fit to a sequence of events that otherwise, independently, have no inherent meaning. When we experience these events, in the moment they are chaotic, "a wreckage of shattered glass and splintered wood." We only later try to fit them into a story to attribute meaning to them. Another way of looking at this is that no independent events can be understood until they are put into a wider context, which is what a story provides.