With the help of blocks, adding any code to header/footer in Codoforum is very easy.
This is very useful when you want to add any analytics code for example. 'google analytics'
Open backend -> UI Elements -> Blocks
Create a new block by clicking 'Add block' button.
Give any name to the block.
Set the Block region as block_head if you want the code to load in the header.
Set the Block region as block_footer if you want the code to load in the body.
Keep the Block output option as 'HTML'
Copy paste your HTML in the textarea given.
Click on 'Save' button
Refresh your webpage and see if the code is running.