HI @Arohan_Ajit,
This error means that your Conv2d layer receives a [batch_size, 3, 224, 224] layer, so a 3 channels input. But as you defined it, it expects a 512 channels input:
squiz.classifier[1] = nn.Conv2d(512, num_classes, kernel_size=(1,1), stride=(1,1))

Changing it to:
squiz.classifier[1] = nn.Conv2d(3, num_classes, kernel_size=(1,1), stride=(1,1))

should solve your problem.