First, select the title of each article in the document and set it as "Title 1", put the cursor at the beginning of the document, "insert-reference-index and table of contents-..."
This will generate a "table of contents" at the beginning of the document. When you press the CTRL key and click the title of the directory with the mouse, it will automatically