Termination is a disciplinary action, whereas resignation is a voluntary action. In my opinion, it is not necessary to give a notice period for termination because you will terminate an employee only when they are found guilty of some wrongdoing. However, if a notice period is provided in termination, it is not a bad practice either. By giving notice, you offer the terminated individual an opportunity to improve themselves and provide them with some space to manage their personal and professional life.
The number of days in the notice period for resignation is typically a contractual obligation between the employer and the employee.