Difference between concur and agree

Dear Teacher,

Could you explain on what instances either of these words(concur and agree) be used.

Thanks

Hi,
What I managed to google:
“Should I say I agree with you or I concur with you? Agree and concur mean the same thing in this context, but the latter is more formal. Both words may be used with or without with. /I agree. I concur./
…usually they mean pretty much the same thing. However, concur indicates that the speaker came to the same conclusion on their own beforehand, or that the conclusion was reached independently whereas agree doesn’t necessarily indicate that.”