A Middlesbrough man who turned to dealing to fund a headstone for his father’s grave has narrowly avoided an immediate prison sentence.