VAT calculation on shipping costs in the purchase invoice

Hello. How can I reflect Shipping costs for the product on my purchase invoices? Should I open my Shipping service as a product card or add it as a Shipping rule? The problem is that when I want to act as a shipping rule, I cannot apply tax to the shipping fee.