If you need to edit a chat message you've already posted, hover your mouse over the message. When the menu items appear in the upper right corner of the message, click the 3-dot menu and select "Edit message". Once you've finished editing your chat message, click anywhere outside the message to save your updates. Most edited chat messages show a timestamp of when they were last changed. You'll see the timestamp at the end of the message, except in cases where the entire message has been deleted.
If you'd like to completely remove a chat message, simply follow the steps above and then delete the entire message. Once you click outside the message area, you'll see the text "Message was deleted".