That’s exactly what Hogg and collaborators found across several studies where they directly manipulated people's identity uncertainty with a brief psychological intervention.
Participants who felt more uncertain about their own identities, *and* were presented with a highly coherent group, were more likely to come out feeling strong identification with that group.
In uncertainty, we gravitate toward compellingly coherent groups. Those two pieces can lock together like LEGO