Postpartum bodies, hormones, minds, and emotions are as complex as they come, so it's difficult to isolate what causes some women to experience Postpartum Depression (PPD) or Anxiety (PPA), especially those without prior history of depression or anxiety. According the NIH website, one component may be the absence of breastfeeding or adequate lactation levels. (Awesome! Like having trouble breastfeeding isn't hard enough already...)
It is often observed that failure to lactate and the onset of PPD occur at the same time. Low levels of oxytocin [the hormone that regulates milk let-down and synthesis of breast milk] are particularly observed in PPD and unwanted early weaning. (NIH.gov)
Preparing for breastfeeding and putting support in place to help you breastfeed is actually an act of love for yourself as well as your baby. The hormones involved in lactation can act as a protector against PPD. It's not a guarantee, but it's another reason we are so passionate about enabling mothers to express breastmilk as long as they want to and as much as it's in their control to do so.