a VirtualTourist member
Is it possible to rent a car in Ancona and pick it up near the train station
Yes, if you pick the right company. For example, Hertz appears to have a location at Via Flaminia, 16, which appears to be across the street from the train station (more or less). Avis' location is out at the airport (as is the main Hertz location). There is almost certainly bus service from the train station to the airport.
I didn't tried Europcar, a common European brand - I'll leave that to you.
NOTE: the Hertz office near the train station has limited hours:
"Hours of Operation: Mo-Fr 0800-1230 1500-1900, Sa 0800-1230, Su closed"
This is typical of car rental locations in the city centers in Italy: closed for lunch, Saturday afternoon, and all day Sunday. Therefore, if you need a car at those times, you'll have to go to the airport, where the hours are normally every day all day long (but check)...