You would think so, but its not the case. Your leave entitlement accrues regardless whether you are working or not. That means when you are on extended leave, parental leave or take a sabbatical, you will continue to accrue leave at your normal rate. But the respective pay is determined differently, for instance for parental leave, the 12 months period prior to going on annual leave is used.
Interestingly, the same principle also applies in Germany. Holidays accrue even when long term (unpaid) special leave is taken as all what is required for the accrual is an employment relationship. However, the employment agreement can provide for different rules and the parties may agree that no accrual takes place during unpaid long term leave.