You may want to read my older note on this subject: https://forum.duolingo.com/comment/30304525
Keep in mind that in some sense English structures like "It was a good woman who did this." result from the fixed word order in that language. In Czech, replicating that mechanism is like driving a manual transmission car in second gear all the time for fear of touching the clutch. We would instead simply switch it up, such as to "Toto udělala dobrá žena." This is what the word order really lets you do; it's not just "anything goes" with nothing to show for it.
I'm not sure I really understand your question, but...
This is the familiar to je/to jsou construction in the past tense. As I understand it, when that construction moves into the past tense, the verb aligns with the noun on the receiving end, so to speak, if that noun can be the subject of a sentence. Here we have žena. which certainly can be the subject of a sentence. So we also have byla, matching up with žena, rather than bylo, matching up with to.
This explanation may be a little rough, but but one of the Czech natives on the team will weigh in if I've missed or misunderstood something.
I am thinking that perhaps "to" is the general designation of a "thing" whatever gender, but in English we do not usually say "that" when referring to a person, so it has to be translated as "she". However, for emphasis we could say "THAT was a good woman!" Am I right in suggesting that "to" is a general, all-inclusive designation?