Second level directory rendering

I am having an issue with the second-level directory rendering, I want to group my content inside the content folder(as content/product/xyz which will inside have different markdown files with different types) and in layouts also the folder structure should be product/xyz.html,product/abc.html. I was having problem in the url as to fetch it like localhost:1313/product/xyz, localhost:1313/product/abc but it does not render like that it renders perfectly when I do localhost:1313/xyz. How should the layout look like. when I tried putting it inside products/xyz.html somehow it was taking blog layout structure and not the structure that was specified for the product. Can anyone help me with this?

Let us see your code

Include a link to the source code repository of your project, because we really need the context of seeing your templates and partials to be able to help you. It is trivial to do a quick git clone on your repo, then run hugo server in your project, to help you out. On the other hand, recreating your code from screenshots, or sort of guessing at it, is not.

If you can’t share your repository for whatever reason, consider creating a dummy repo that you can share, which reproduces the problem you’re experiencing.