Salary & Tax calculation issue

How do I apply the payroll multiple tax roles in the payroll module in ERPNEXT. When I put the new role in the income tax slab, it is calculated almost wrongly. It is calculated over the course of the year, paid and remaining, and with the same salary every month, the value of the tax will look different. Is there a solution or another way to apply the tax?

You can create Salary Component for different Tax and put the tax formula in it.

This way you can apply the tax for monthly payroll.