Something similar to this: emacs-org mode and html publishing: how to change structure of generated HTML

I want to have more control on the layout of HTML files generated from org-mode files. The default layout is good, but not good enough for my needs.

How can I change the default layout for any custom one?