I was using different runtime for python while building and creating layer.
I changed the both runtime to python 3.11 in layer and in linux during zipping aswell.
Thanks!