Keep in mind that for accounting purpose, there are two types of leases:
1. Operating Leases
2. Finance Leases
I assume that by saying capital leases you mean finance leases. The accounting standards are very detailed about what should be considered a finance lease and how to recognize it. For example a finance lease is any asset that you bought where the risks and the rewards have been transferred to you. For example, if you are responsible for the asset (maintenance etc), the risks and the rewards are with you.
In addition, if the price that you pay is the fair value of the asset plus finance costs, it is essentially like buying an asset but instead of paying upfront, you are allowed to pay in instalments Furthermore, if you lease an asset for 5 years and the asset is expected to last for five years, it is like you have bought it since by the time that the lease is complete, the asset will have no economic life left.
For the above reasons, finance lease is like you have bought an asset but you have agreed to pay a bit of the total value per year (or in any other arrangement). Therefore, if you enter into a finance lease, you acquire the asset and you should recognize a liability (or as you said a debt). The debt is reduced by the repayments you make every years (interest is applied on the balance that remains too) and should be split between a current liability and a non current liability.