We can create new element in HTML page using javascript, We have to create element and then we should append it to existing element.
<div id="home">
<p>DotNetFunda</p>
<p>TechFunda</p>
</div>
<script>
var a = document.createElement("p");
var b = document.createTextNode("ITFunda");
a.appendChild(b);
var c = document.getElementById('home');
c.appendChild(a);
</script>
In the above code we have created two paragraphs with two values and in the script function we have created "element p" and created text for the "element p" and we are appending "a with b" and we are having var c with id as home to append "c with a" which creates Text for new paragraph as ITFunda.
OUTPUT
DotNetFunda
TechFunda
ITFunda