Given the circumstance, I feel that they might not actually care whether the Thanos they are looking at is the one they faced 5 years ago.
However, to answer your question, I would say yes, they do know that Thanos came from the past.
The first evidence comes from Tony's line when he woke Steve up. Steve asked about what happened, and Tony replied:
You mess with the time, the time messes back. You'll see.
This shows that Tony is aware of the consequences that might come with time-travel.
The second is from Wanda's brief conversation with Thanos just before the duel between those two.
WANDA: You took everything from me.
THANOS: I don't even know who you are.
WANDA: You will.
Wanda definitely knows.
The third evidence is actually pretty obvious: Nebula. Assuming Thanos took quite some time in 2014 to gather his army before Nebula 2014 took him to the future, Nebula 2023 was there. It would be a shame if she doesn't talk about her trip, maybe in a "Boom, you looking for this?" style.
There is more than enough evidence to support the yes in your question, so I'm gonna stop at 3 details that I can quickly remember for now. Maybe they actually talk about Thanos' identity during the battle but offscreen. You never know.