The study revealed how long you should lift weights for and how many times a week to boost longevity