What I want to do is to convert images to RGB888 in order to increase significant figures of each pixel. I noticed that when I type for example print([img[2000]) , I get a list of 3 numbers coded in 8 bits, but I think that it is just a linear conversion of a number coded in 5 bits ( or 6 bits for the green component)

So I tested that by typing for example :
img = sensor.snapshot()

img[2000] = [ 23, 30, 23 ]
print(img[2000])

I get :

(25, 28, 25) instead of (23, 30, 23)(The values that I gave)

So I wonder if there is a way to convert to rgb888 in such a way as to increase the number of significant digits.

Nope, we just have two images types: RGB565, and grayscale (8-bits), and we'll be adding binary very soon too.

If you want RGB888 data please set the camera mode to RAW and you'll get a bayer pattern in the frame buffer. All our image processing code work won't on a bayer pattern... but, you'll be able to save jpegs and you can manually access the pixels which are now 8-bits each using set_pixel() and get_pixel().