Graph homomorphisms through random walks