Hi Wun,
Thanks for your inquiry. Please use CompositeNode.InsertAfter/InsertBefore method to insert the specified node immediately after/before the specified reference node.
If you face any issue, please share your input and expected output documents here for our reference. We will then provide you more information about your query along with code.