get the z370-a
since you are running the 8700k, which can be quite power hungry, especially under load.
from what i can see/predict.
both uses 4+2 vrm
z370-p uses a 4+2 vrm with 1 high/2 low per phase core, 1 high/1 low per phase soc
z370-a uses a 4+2 vrm with 2 high/2 low per phase core, 1 high/1 low per phase soc.
z370-p is the cheapest z370 asus offers. and z370-a is mid range board.
excluding features, the vrm on the z370-a is stronger. it can handle more current to the cpu and keep it cooler than the z370-p.
both should handle stock 8700k without issue.
to be honest, either are not very good @ overclock the 8700k,
let's say 4.7ghz (running max single core tb on all core)
i would think 4.7ghz should be doable on the z370-a, given that your case air flow is good.
z370-p you might run into issue due to vrm overheating.
if i had to choose, i will go with the z370-a, and only put a mild oc (4.6-4.7 ghz) over it on 8700k, 8600k should be okay to run @ 5.0ghz.