possible, yes.....but i'm gonna say don't do it as imho, it will take about 30-45 minutes each way but more important, i think you'd get stopped by sfpd as you will be walking on a service road which has direct access to the tarmac to the tarmac (and iirc, there are no sidewalks and folks (myself included

) drive that road a bit too fast.
there is a post out here somewhere about a millbrae shuttle from sfo to the bart station which iirc, is free but i can't find it.
personally, if it was me, i'd either take bart, look for the shuttle or grab a cab as the last time i took a cab from sfo to millbrae bart*, it was maybe $5-$6.
*mis-conx coming home and arrived at 2am and missed the last bart train at 1 by a mile