I don’t think that is the correct way to do this. You will need to pass your tensors to specific layers to get their individual outputs. Something like this will work:
import numpy 
import tensorflow.keras.models as models
import tensorflow.keras.layers as layers

cnn = models.Sequential([layers.Conv2D(64, 3, 1, 'same', input_shape=(32,32,3), name='cnn1')])

# Get the convolutional layer
layer1 = cnn.layers[0]    ​
# Call the layer by passing your tensor to the layer
layer1(numpy.random.random((1,32,32,3)))