It was narrated from Samurah that the Messenger of Allah (ﷺ) said:
"The two parties to a transaction have the choice (of annulling it) so long as they have not yet parted. " (DE)
English reference (DE): Vol. 3, Book 12, Hadith 2183 (DE)
Arabic reference (DE): Book 12, Hadith 2267 (DE)