McDonald’s Corp. is revamping its approach to diversity, equity and inclusion, becoming the latest large company to change its strategy as the once-ubiquitous goals come under pressure from conservative advocates.