Search for heavy resonances decaying to a W or Z boson and a Higgs boson in the q q ¯ ( ′ ) b b ¯ final state in pp collisions at s = 13   TeV with the ATLAS detector