Right after you send a message, you’ll see the message “Sent” and the option to Undo.
Tap Undo.