The S&P 500 set another record high on Monday as the market continued to rise in the final days of August.