Hello,
If the latest release of LibreOffice returns the same output then SECTIONPAGES is not fully supported by LibreOffice yet. In this specific case we can't force LibreOffice to work as needed, as it seems it's a not supported field.
In this case, as alternative approach, you can generate a PDF (using transformDocument and NumPages instead of SectionPages if needed) for each DOCX and then merge them into a single PDF output using mergePdf.
Another approach could be using custom bookmarks instead of merge fields to set the page total: https://www.techrepublic.com/blog/windows-and-office/pro-tip-calculate-the-current-page-number-within-a-section-in-word/ (by inserting a Bookmark ‘section end’ at the end of the template and adding a ‘Reference tab’ to this bookmark in the footer of the template).
Regards.