Taking key as parameter an rename cipher method