Deliberate mistake: Elsa's dress in Season Four is different from the dress she was wearing in the Season Three finale. The new dress is a different shade of blue, and has a completely different design, even though the present day events of Season Four take place mere moments after the end of Season Three.
Continuity mistake: When Elsa is walking down the middle of the street through Storybrooke, she is leaving a trail of ice on the road behind her. Shortly after seeing a wedding dress in a store window, she walks towards the store, and the trail of ice behind her is gone. (00:07:00 - 00:07:35)
Answer: He knows who she is because he knows that the fairy tales are true. He was also shown to sneak out to go see Emma or someone else. Sometimes he succeeded, sometimes he didn't. This is how he knew to look for her despite his strict mother.