U-blox NEO-M8P I2C on atmega328p

I think it supports only UART communication

Well, according to the front page, it supports "any kind of input stream". Just read the bytes from I2C and pass them to the handle routine. Or, if you have an I2C class derived from Stream, you can pass it to the available() method.

Be sure to try this with a standard 328-based Arduino, first.

BTW, you probably don't need to use the binary UBX protocol. Try the standard NMEA text messages first.

Cheers,
/dev