Kenya’s High Court upheld the validity of a tax measure that President William Ruto is using to raise funding for affordable housing, boosting his attempts to steady the nation’s finances.