Template does not save page number property

I want to create sequential numbering in my master document. I followed the instructions given there: https://wiki.documentfoundation.org/images/3/32/0213WG34-WorkingWithMasterDocuments.pdf

I created a template and I modified the properties of Heading 1 paragraph style. I changed the text flow property and added a break with page number 0. Somehow or other the template file saves all the style changes except this. I tried various tricks for hours. However, I failed. Each time I reopen the template file, the style setting for H1’s page number is greyed out or unselected. It doesn’t save the page number property for Heading 1 as 0.

I want to use master documents to write a book with sub-document chapters. Has someone achieved success with the tutorial given above? Can someone please shed some light on this issue or share a master document with few sample chapters which I can populate with my content?

I found a workaround by using text enteries and adding manual page breaks.
https://forum.openoffice.org/en/forum/viewtopic.php?f=7&t=77613#p354889