I have a question regarding construct HTML tags on back-end code (c#) in my ASP.NET application.
Let say I have a DataTable as below:

I would like to dynamically convert (using multiple foreach and if else condition) the DataTable into a form of ul and li as below:

Finally my expected output:

what is the best practice of achieve this? Please help.
Thank you in advanced.
Updated: I've found another alternative solution from this post How do I display non-normalized data in a hierarchical structure?