Can someone please explain Rhesus incompatibility?

Lets say we had a Rhesus negative mother who became pregnant, with a foetus who was Rhesus positive. During the course of the pregnancy, there is very little exchange of blood between the foetus and the mother, so this has no difference. However, after childbirth when the placenta separates from the uterus wall, there is an exchange of blood. As a result, these rhesus positive blood cells are detected as foreign, 'non-self' because they do not belong to the mother's cells. Thus, the mother will antibodies against rhesus blood type. As a result, if the next child is Rhesus positive, the immune system of the mother will detect the foetus as 'non-self', and so devise an attack to destroy the foetus, resulting in a miscarriage.