We need some background on the charging problem. Was the battery not being charged the reason you installed the new alternator? Or did the problem start after you replaced the alternator? Any additional info you can give us would be helpful. Don't assume the alternator is good just because it is new.
I agree with Jon. How did you get the alternator? If it's from a parts store or a salvage yard, tell them you got the wrong one and exchange it for a new one. There are so much electronics and sensors it would be hard to say what your issue is.
If it's a "free" alternator it's no longer free.