How do I get moisture out of iPhone 6?

I can see the moisture in my camera and it's been in rice for 4 days. I've taken it out 2 times and sometimes the screen is just black but then it works fine and then randomly turns off

If you have powered it up when there was moisture in it, your phone has fried.

Rice to dry the inside of phones etc. Is an urban myth.

The only way to (hopefully) prevent them being wrecked by water or moisture is to turn them off (and remove the battery if it'a a type where that is possible) and get them to a repairer as quickly as possible.

They must be dismantled and all the electronics need washing with deionised water and alcohol, to remove all traces of contamination, then fully drying before it's re-assembled.

Ask apple

May & should have it professionally seen about.