It seems that for odd and even pages you don't set left
and right
positions of page numbers but you need to set outside
and inside
positions of them.
So, try to change this tiny line:
.Add (0)
into one of possible 'odd-even' positions:
.Add wdAlignPageNumberOutside
.Add wdAlignPageNumberInside
Moreover, last line which is trying to insert 'tab' is not necessary then.