I read somewhere that you can’t do this. Is there anything a person can do to purify themself.
Please provide sources.
I read somewhere that you can’t do this. Is there anything a person can do to purify themself.
Please provide sources.
As, Ezra stated in the comments (I've not seen that until I published this answer), if you are a Kohen, then this does not apply to you, since a Kohen is not allowed to become impure through this.
The Kitzur Shulchan Aruch 199:14 says:
It is forbidden to step upon graves because some Poskim maintain that it is forbidden to derive benefit from them. However, if you have to visit a certain grave, and have no way of getting there unless you step upon other graves, it is permitted.
Regarding washing after leaving a cemetry, see this answer.
The Magen Avraham (4:20) writes that you can wash yourself (netilat yadayim) after visiting a cemetry because there are bad spirits (שדים)
בין המתים. היינו בית הקברות (תשובת מהרי"ל סי' כ"ג) וכתב שיש ליטול קודם שיתפלל על הקברות ורוחצין שנית בשובו לחצר בה"ק שהשדים מלוין החוזרים ויש לרחוץ גם הפנים עכ"ל ע"ש:
See also: Mishnah Berurah 4:42:
and wash a second time upon returning to the courtyard of the cemetery, because evil spirits accompany those who leave. There are those who also wash their face at that time.