"Purpose" has different meanings for HMDA versus Community Development under CRA. CD loans under CRA are recorded only as originations or purchased loans. Under CRA and community development a loan must have its "primary purpose" as a qualified CD activity. The MF mortgage would qualify as CD under CRA if the rents are affordable and the majority of the beneficiaries are LMI tenants. Alternatively, the primary purpose test can be fulfilled if you have an explicit statement from the borrower that there are X% affordable units for LMI tenants.
Anyway, "refinance" is not an issue for CD loans. It's the "primary purpose" that's relevant.
_________________________
CRA Exam Preparation, CRA Performance Evaluations, Key Performance Benchmarks, & maps