To block a direct message, follow the steps for Unfriending a user.
Once you unfriend someone, they will no longer be able to message you directly and you will no longer be able to message them.
You can always re-add a user as a friend if you change your mind, which will restore your chat history.