No, the code just "Nests.' Indent.
Remember EPUB2, NCX is the 'real' TOC for devices,
since you want it to start 'collapsed':
Make the NCX entry point to a page (XHTML) that is the 'Contents for that sections Start. Those items (links) will never be in the NCX
Generate a overall HTML TOC page (from the nested
monster NCX). Split it into 'Sections' and move those to the beginning (location in the file list) of their respective places. rename the files for clarity eg TOC02, TOC03... and Insert an top level Chapter (number) title at the beginning, that will be picked up by the TOC Generator tool in the next step
ie <h1>Section x Contents </h1>
now regenerate the NCX, but restrict (the pulldown is at the bottom) to only the top levels assigned to the Sections TOC : h1
Doing it in this order, lets Sigil do the tedious, "get the links correct" part

and leaves it to you to push the big chunks around