Final answer:
To change the retention period of a message in SQS, the SetQueueAttributes action is used to modify the MessageRetentionPeriod attribute to a value between 1 minute and 14 days.
Step-by-step explanation:
To change the retention period of a message in Amazon Simple Queue Service (SQS), you would use the SetQueueAttributes action. This action allows you to set the message retention period attribute (MessageRetentionPeriod), which can be modified to a value between 60 seconds (1 minute) and 1,209,600 seconds (14 days). When using the AWS Management Console, CLI, or SDK, you will specify the attribute name and the new retention period value to update the setting for your queue.