To cast off (also known as binding off) means to remove the stitches from your needle.
You do this when you have finished knitting the section of fabric you are working on. This is how to do it:
On a knit row, knit the first two stitches so that they end up on the right needle
Push the left needle through the front of first stitch on the right needle
Pull this stitch up and over the other stitch and then completely off the needle - the other stitch should remain on the right needle. This can be a bit fiddly, so take your time
You will end up with one stitch on the right hand needle, as shown. Knit another stitch, then repeat steps 2 to 4 until you have one stitch remaining on the right needle. The final step is to cut the yarn (leaving about 10cm attached to your knitted piece) and to thread the end through the last stitch, pull it off the needle and pull tight