Maliks Muwatta Book 20, Hadith Number 158.

Section : What to Do with Sacrificial Animals (Hadys) if They get Injured or Stray.

Yahya related to me from Malik from Nafi that Abdullah ibn Umar said, “If someone dedicates an animal and then it goes astray or dies, he should provide a substitute, if it was for a vow. If, however, it was voluntary, then he can either provide a substitute for it or not, as he wishes.”