The CARMENES search for exoplanets around M dwarfs -- Planet occurrence rates from a subsample of 71 stars