The FFL you bought the firearm from retains the federal form 4473 that you completed for 20 years. If the firearm you bought turns up at a crime scene or some such, it can be traced, via the serial number, by the feds from the manufacturer, to the distributor, to the dealer and then from the dealer to you.
When the background check is made, no information about the firearm is given to the FBI other than stating whether it is a handgun or a long gun. If your state does not maintain a regictry, then the firearm is not registered. Some people misunderstand the background check process and believe the check registers the firearm to them.