To create and append an div tag to your document's BODY, this should do the trick:
elt = document.createElement('div');
document.getElementsByTagName('body')[0].appendChild(elt);
If Javascript is turned off, that won't work. As far as I know, there's no way to append, show, or hide a page element by clicking something if Javascript is turned off.
To show or hide a particular element, you need a variable reference to the element. If the element has an ID like this:
<div id="myDiv">
then you can get a variable reference to the element like this:
var elRef = document.getElementById('myDiv');
NOTE:You can only call document.getElementById after the element in question has been rendered and possibly only when the whole page has been rendered. I think this may vary by browser.
Once you have a reference to the element, you can hide it like this:
elRef.style.display = 'none';
and show it like this;
elRef.style.display = '';