JSFiddle - React, Tailwind, and code Playground

HTML

<ul class="cList">
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
     <li>...</li>
</ul>

JavaScript

$('.cList').each(function() {
    var thisList = $(this).find('li')
    var thisLen = thisList.length
    for(var x=0;x<thisLen;x++) {
        if((x % 5)==0&&x>0) {
            $(thisList).eq(x).after("</ul><ul>")    
        }

    }
})