Scientists believe they have uncovered one of the mechanisms that enable the brain to form memories.