The answer is "it depends". When you delete a text message on your iPhone, the message is just marked as "deleted"; at some point in the future, the spaces for those deleted messages are reused. If the space has not been reused yet, the message can be recovered.