One of the things I've often heard said is that most texts of ancient mythology are pretty much fan fiction, since they reuse and repurpose characters that already exist. "Virgil was writing Homer fanfic" is the way it's often phrased. I'm not too sure that the equivalence is as strong as it's sometimes claimed to be. For a start, the concept of fan fiction is predicated on the idea that there are 'official' and 'unofficial' stories set in a particular megatext, and that the official stories hold an essential position of privilege over the unofficial ones. That's not really true in ancient literature - not even Homer is quite treated in that fashion. Still, what the comparison does show is that fanfiction, telling new stories about characters in stories that we've heard, is a manifestation of an urge in human storytelling that has very deep roots indeed, and that making the creation of original characters a sign of a superior writer, a stick that is often used to beat fanficcers, is a fairly recent idea.
Anyway, Juliette Harrison has written an interesting blog post on this subject. And Ika Willis will be editing an issue of the Journal of Transformative Works that addresses Classics and fanfic, If you want to contribute you have until 1 March.