I know this is an old post, but I found it in my search for the same info and I've solved the issue.
I have XML that looks like this:
<soap:Envelope xmlns:soap="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
<soap:Body>
<LoginResponse xmlns="http://example.com/WebServices/">
<SessionID>xxx</SessionID>
<LoginResult>Success</LoginResult>
</LoginResponse>
</soap:Body>
</soap:Envelope>
So the XPath can look like this:
declare namespace b='http://example.com/WebServices/'
//b:LoginResponse
Notice that the response XML doesn't use the 'b' namespace, but I'm assigning the default namespace URL to b in the XPath query and then using 'b' in the query. This worked for me.