Tenrec correctly states that you can simply drag a desktop icon onto the taskbar. However that won't work if the taskbar is locked. Right-click on the taskbar and check to see whether there's a tick alongside 'Lock the taskbar'. If so, click to remove the tick. (After adding your icons, repeat the process to lock the taskbar again).
Dragging a shortcut icon to the taskbar only copies it. You'll then need to right-click on the desktop icon, and select 'Delete', to remove it.
Alternatively (and probably better) you can clear all of the desktop icons by right-clicking on the desktop and removing the tick alongside 'Show desktop icons' (which is under 'Arrange icons by').
Chris