Quantum theory of Kerr nonlinearity with Rydberg slow light polaritons