Hugo convert image links in Typora documents to level deeper

I use Typora to write documents and insert images. The data structure is: each post is stored with all their images in a separate folder inside /content/posts folder, for example new_post. Typora settings is “Copy image to current folder” and “Use relative path if possible”. Accordingly, in the md document, the link to the image looks like this:
" img1 " - and in Typora all works fine.
When i use Hugo it convert these links for some reason to level deeper, expecting that in the post folder will be subfolder (with the name = name of the article) and all images will be in this subfolder. Accordingly, in the article “Madrid_2023” in html file, the generated link to the image looks like this:
http://…/posts/new_post/madrid_2023/img1.jpg
Because the subfolder madrid_2023 does not exist - images are not showing :frowning:
If i create manually a subfolder madrid_2023 and move images there - in Hugo all works fine and I can see images.
Q: Is it possible to avoid manually creating subfolders for images in every post folder? Why Hugo convert all image links to level deeper and can it be turned off?

Try naming the Markdown file to index.md instead of madrid_2023.md.

Per the doc page on page bundles in Hugo:

This leaf bundle has the index.md, two other content Markdown files and two image files.

  • image1, image2: These images are page resources of my-post and only available in my-post/index.md resources.
  • content1, content2: These content files are page resources of my-post and only available in my-post/index.md resources. They will not be rendered as individual pages.