Portugal plans to adapt its golden visa scheme to allow wealthy foreigners seeking residency rights to invest in affordable housing for locals or accommodation for migrants.