Influx retention config

I would need help. My influxdb is already 10gb and is constantly increasing. Retention policy is in default - infinite. I would like to change it so that the database does not continue to increase unnecessarily. My idea is - 1 year without change, 2nd year every 5 minutes, 3rd year every 15 minutes, 3rd year every half hour, 4th year and more every hour. How could I do it and the main question is - will it help to reduce the size of the database?