All your messages are stored locally on your device, so the messages you send only exist on Signal’s servers during transit where they are end-to-end encrypted.
As long as your phone is safe, your Signal messages are safe as well.
Because your data are only stored locally you have to perform a backup of your messages if you want to keep them after changing your phone or before installing LineageOS. Therefore you have to create a backup-file.