There are many books which describe the defense mechanism of the ego- one of my favorites is Anna Freud's Ego and Mechanisms of Defense - it is a classic and it should be easy to find.
You are asking an interesting question in terms of how one deals with anger, aggression and punishment. I think you are suggesting that a mpd patient is turning his or her anger toward him or herself? It certainly seems to be the case that one can feel that one deserves to be punished and hurt and takes actions that will result in hurting one's self. I am not sure that you need to call it the work of an alter. The mind in control mastery theory has the capacity to make plans and put them into action. Theses can result in actions that are self destructive if one feel very guilty and fears that to do otherwise will endanger a love one.