Yes, "dig him a grave" means "dig a grave for him." I don't read a lot of poetry, so I cannot say for sure if it's commonly used there, but we don't usually say it in everyday conversation.
However, we do have an idiom: digging one's own grave. This idiom means someone is making choices leading to their own death and/or downfall. For example:
"The president dug his own grave when he fired his bodyguards, leaving him unprotected from those who wished to assassinate him."
I hope this helps. Please let me know if my answer isn't clear.