In your forward method you are directly flattening your input x and passing it to the linear layer skipping all conv layers.
I assume you would like to pass the input first to self.conv1, self.pool etc.
You are also redefining the modules inside the __init__ method, so use different names for the layers.
This tutorial 11 might be helpful.