Massachusetts would allow local option real estate transfer taxes as part of a $4 billion package announced Wednesday by Democratic Gov. Maura Healey to tackle the state’s affordable housing crisis.