How not to render content as a page

Yes, there is a way.
Put this into the baseof.html
{{ if .Params.render }}
page goes here
{{ end }}
And put this into frontmatter of pages that should be rendered
render = true
All other x.md files will not be rendered by hugo command.
Note: the hugo server will still render all pages.
Note: also put the code into the sitemap.xml How to omit page from sitemap (But use current sitemap.xml from https://gohugo.io/templates/sitemap-template/)