custom tensorflow layer that inherits another class
Although I'm not an export of RNN's, the following should work given that RNN is inherited from Layer:

from keras.layers import RNN
class custom_LSTM(RNN):
   # implementation of class
   ...


It might be good to provide the smallest piece of code that can reproduce your error.