In addition to the answer, Alex Art from October 30 at 21:05:
You can use the ssi_last_modified directive with the value on
Syntax: ssi_last_modified on | off;
Default: ssi_last_mod off;
Context: http, server, location
This directive appeared in version 1.5.1.
Allows you to save the “Last-Modified” header field of the original response during SSI processing for better caching of responses.
By default, the header field is removed because the content of the response changes during processing and may contain dynamically created elements or parts that have changed independently of the original response.
Source: http://nginx.org/ru/docs/http/ngx_http_ssi_module.html