Merge pull request #3822 from libgit2/ethomson/checkout_head_docs documentation: improve docs for `checkout_head`