var h = document.getElementById("myH2");
h.insertAdjacentHTML("afterend", "<p>My new paragraph</p>");
let target = document.getElementById("ID");
target.innerHTML += "<p>CONTENTS</p>";
<script src ="path/your js file name"></script>
document.getElementById('tag-id').innerHTML = '<ol><li>html data</li></ol>';
//add new created html : where to insert, what to insert
element.insertAdjacentHTML("afterbegin", html);