The kernel size is defined as [out_channels == number of kernels, input_channels, height, width]. In your example you are returning 1 output channel in foo_1, which means foo_2 should have in_channels=1.
A simple approach for your problem could be to just append the modules to a nn.ModuleList:
class MyModel(nn.Module):
    def __init__(self):
        super(MyModel, self).__init__()
        self.features = nn.ModuleList(
            [nn.Conv2d(1, 3, 3, 1, 1),
             nn.ReLU()]
        )
            
        
    def forward(self, x):
        for feat in self.features:
            x = feat(x)
        return x


model = MyModel()
x = torch.randn(1, 1, 24, 24)
output = model(x)

# Add new layer
model.features.append(nn.Conv2d(3, 6, 3, 1, 1))
model.features.append(nn.ReLU())

output = model(x)

Let me know, if this fits your use case.