Too tired to look it up but wasn’t he talking to His brother James?
James & Mary were already son & mother, so I have always heard it was John - that Jesus was commanding them to adopt each other as son / mother since Mary’s other son(s?) had not (yet) become His followers & Mary would be better served by John due to his faith in Jesus.
I thought James became a believer after the resurrection. John 19:26 said it was “the disciple whom He loved standing nearby.”
How could the author say there were no apostles at the crucifixion?