I don't know if the spelling is right, I have never read it, only heard. I have heard it around Munich several times. It was used when someone dropped glass from his hand or similar situation.
I cannot find anywhere. What is the exact meaning?
I guess, it's either "Ach, Mann" or "Ahh, Mann".
I would translate both expressions to "argh", which is an onomatopoeia for annoyance, frustration or embarassent. I use "Ach" more for embarassment and "Ahhh" more for annoyance/anger towards myself.
I'm pretty sure you heard "Ach Mann!", which was shortened to "Ah Mann!" because of the dialect in that region.
Or "Ah" was used as something like "aaargh!"
It actually means the same as "Oh Mann". If you would have to make a difference, you could say:
"Oh Mann!" is mainly used to express being annoyed by others
"Oh Mann, können die nicht schneller fahren!?"
whereas "Ach Mann, or "Ah Mann!" is used regarding one's own mistakes
"Ach Mann, jetzt ist mir [auch noch] das Glas ausgerutscht!"
"Ach Mann, der Laden hat heute geschlossen!"
In many cases (especially when it's about annoyance) you could just say
Indeed, it must have been an local pronunciation of "Ach, Mann!", where "Ach" is used as a "Symptominterjektion" german wikipedia about the interjektion Ach.
"Mann" here stands not for the male person, but for humans in general.