code: def stages(self):
          
          stages = list()
          for data in self.data.stages:
              stages.append(StageInstance(session=self._session, data=data, pipeline=self))
  
          return stages
docs: Method for getting stages from pipeline instance.
  
          :return: arrays of stages
          :rtype: list of yagocd.resources.stage.StageInstance