Possible Fix Description – TLDR: In my car, something similar was caused by a bad voltage regulator on a remanufactured alternator.
I had a similar issue with my '02 WRX (199,014 mi). However, the problem was actually *caused* by a new alternator. Here's a quick rundown of what happened:
1. At about 198,000 miles, I noticed that the red [brake] and [battery] lights started flickering on and off sporadically while driving (I drive about 60 mi to work a few times a week). This happened to me several years ago, and it was due to a grounding issue (it was fixed by simply replacing a ground cable that had a loose connection). I took it in to Subaru for another issue with the air conditioner but asked them to look at the grounding as well.
2. Subaru told me that the blinking [brake] and [battery] lights were due to a bad alternator but wanted to charge me $600 parts + labor to replace it, so I decided to replace it on my own.
3. I purchased a replacement alternator from AutoZone. Got it installed on my own, and things seemed great. I noticed that the output voltage when the car was running was 17v (above the 14-14.5v that it should be), but things seemed fine (this should have been a warning to me!).
4. On the way home from work one day (about 350 mi later), the yellow [ABS] started coming on sporadically. Then, after about 20 more miles, the Speedometer and Tachometer started sporadically dropping to 0 and then popping back up to the proper readings. Though the car seemed to be running fine, I decided something was badly wrong with my car and decided to drive to Subaru instead of home.
5. About 1/2 mi from Subaru, the car started sputtering and stalled at a stop light. Pushed it, got a jump start, and finally made it to Subaru (at about 8pm).
6. Subaru looked at it the next day and couldn't find anything wrong. They suggested that it might have been caused by corrosion on the battery terminals, cleaned them up, charged me $115, and gave me my car back.
7. I drove for about 10 minutes and immediately started experiencing the same issues. Stalled by the side of the road and had the car towed back to Subaru.
8. They look again, can't find anything wrong. They drive the car, test again, and nothing is wrong. They drive it again and test for a third time, and suddenly my alternator is putting out 0 voltage. Both Subaru and AutoZone agreed with me that it was probably a bad voltage regulator.
9. I had the car towed to my place and called O'Reilly to order a different replacement alternator (AutoZone will give you a refund if the alternator bench tests bad). Got the new alternator installed today, and as far as I can tell, it seems to be running really well now. I ran it in the driveway for about 40 minutes with no issues, so I'm hoping things will be fixed when I head to work this week.
Moral of the story: Just because it's a new (refurbished/remanufactured) part doesn't mean that it's not the problem.