It can be assumed that she knew that she was the stronger of the two involved, so she kept the secret for them both. She also knew what the punishment would be for Dimmesdale and for that reason she kept quiet. Also, there is that hint of rebellion about her, so we can also assume that she didn't reveal the identity because she was making her point to the group about her right to privacy.