To enable TLS1.2 and TLS1.3 in Nginx, you need to modify the nginx.conf file.
Here are the steps:
/etc/nginx/nginx.conf
ssl_protocols TLSv1.2 TLSv1.3;
Now your server should be enabled for TLSv1.2 and TLSv1.3.