Hello,
Sorry, but what do you mean by 'but nothing happend'? If your template has a TOC and you add headings to the document, when you update the TOC in Word the headings must appear.
Another approach, maybe it's easier for your specific case:
1. Create the first and second pages standalone in a DOCX.
2. Create the table of content using addTableContents in another DOCX.
3. Create the other content of the document in another DOCX.
4. Merge all DOCX using mergeDocx (http://www.phpdocx.com/api-documentation/docxutilities/merge-Word-documents-with-PHP)
Regards.