Think about it: Lots of people are amateur painters, amateur actors, amateur standup comics, and so on. Do you know anyone who is an amateur writer? If you tell someone you write, their first question is inevitably "are you published?" If someone tells you they like to paint, do you ask "have you sold?" Or: "Are you in any museums?"
Leaving aside the fact that fan fiction has become a significant percentage of the SF/F market (tell me that the Star Trek, Star Wars, or Buffy novels, etc., aren't fan fiction!), why should you feel guilty or embarrassed to be an amateur writer if it gives you and other people (however few) pleasure? A number of writers have said they write for themselves alone. ("When I want to read a good book, I write one." -- Benjamin Disraeli) I don't think most of them meant it literally; but if it satisfied them, that was enough.
Do I think there is a difference in quality between fan fiction and published fiction? On average, sure, there probably is. But that's not the point. You can use fan fiction to develop skills that enable you to get published, or you can use it as an end in itself, for the sheer pleasure of writing, or even just to explore an idea you got in someone else's world. But in any case I wouldn't be ashamed of it. If you are, then you either need to get over it, or give it up and get serious about getting published.
Writing is a very difficult task. It combines a number of very different skills, and it shows quite readily if any of them are missing. Fan fiction at its worst may avoid dealing with developing characters, universe, or sometimes even plot--but it does help one practice skills required for any fiction, if only (as one person noted) mastering the language. Writers write, period. The more you write, the better you are likely to become.
My wife pointed out as we discussed this that in the visual arts you always start out copying people. Jules Feiffer referred to this as "swipes" when he was doing comic books. Everyone would "swipe" good art from other artists, and indeed many comic strips today have a stable of artists who all draw carefully identical styles. Garfield is an example of this, and Jim Davis himself started out drawing someone else's comic until he struck out on his own. Every artist I know--and I know many--started out imitating other people until they developed their own style. What is fan fiction but prose "swipes?" If you get famous and good, you write "pastiches" or "hommages," but, hey, a swipe is a swipe!
Robert Heinlein's previously unpublished first novel, For Us, the Living was recently published. It's pretty lame, especially compared with Heinlein's average work, but it is also clearly based on the style of H. G. Wells, with a dash of Aldous Huxley. Large chunks of the concepts and occasionally other riffs found their way into other, better written works. It's worth remembering that the person who transformed and defined modern science fiction started out doing "swipes" from other people, and also worth remembering that parts of it were good enough to reuse!