It is narrated from Sayyiduna Abu Hurairah (may Allah be pleased with him) that when the Messenger of Allah (peace and blessings be upon him) would go out for the Eid prayer, he would return by a different route.
Hadith Referenceسنن دارمي / من كتاب العيدين / 1652
Hadith Takhrijاس حدیث کی سند حسن ہے۔ دیکھئے: [بخاري 986] ، [ترمذي 541] ، [ابن حبان 2815] ، [موارد الظمآن 592]
Brief Explanation
(Commentary on Hadith 1651)
From this hadith, the Sunnah of going to the Eid prayer by one route and returning by another is understood, so that the trees, stones, and patches of earth on every side may bear the imprint, and on the Day of Resurrection, all may bear witness to this obedience and submission (and Allah knows best).