Problems with heading for endnote section and 'format styles', related to epub conversion

Dear friends,

I am currently working on converting a DOCX / ODT into EPUB format. I learned that it is a very good method to use Styles rather than making linebreaks and other formating manually when you are making an EPUB. So I have been pursuing this without much problems until the time came to make the endnotes section.

For some reason there is no apparent way to create any heading saying “ENDNOTES”. If I try to make a heading according to the ordinary method I did throughout the document, ie. applying Styles and using one of the saved layouts and put this at the very end of the document, then when I try to create an endnote in the main text, the first note would automatically generate a pagebreak and end up on the page after the intended heading. And this is despite the fact that the settings for the heading style in question does not have any pagebreak in its settings. And I can’t find it in the settings for foot- and endnotes, even if I thought it was easily available there…

I would be very grateful for any kind support.

Specifics:
LO version: 24.2.3.2 (X86_64) / LibreOffice Community

OS: Windows 10.0 Build 19045;
19045.4291
22H2

Conversion: Calibre - From DOCX / ODT to EPUB

Endnotes are unfortunately entirely managed by Writer and it is difficult to interfere with the process.

My workaround is to add fake notes.

For a global note heading, I Insert>Footnote & Endnote>Footnote or Endnote so that I can choose the anchor, i.e. a space character. This space character is invisible in text and in notes area. All is left is to apply Heading 1 (if you want the “End Notes” heading to be collected in the TOC) or any other ad-hoc paragraph style.

For chapter heading in the notes, I insert a similar note (with space character as anchor) at the end of the heading. The chapter heading can be added as a cross-reference so that it is updated automatically whenever the heading is changed. Again, apply any suitable paragraph style to this fake note.

PS: when asking here, always mention OS name, LO version and save format. Please notice that most of advanced recipes given on AskLO won’t work with DOCX.

Thank you for your explanation.

And also for reminding me about adding important information to a question. I will do so.