Provided that both parties are listed on the title and are co-obligated on the mortgage, then yes, both are in an equal position in regards to the property. Generally, on a mortgage application, the party who makes the most money is listed first on the application (the “primary wage earner”), though there are exceptions to this.
If a borrower has a “cosigner” , it is possible that that person is assuming partial obligation for the debt, but is not claiming any ownership (is not listed on the deed as a co-owner). This, in most cases, is a riskier position for the cosigning party, but may happen – such as with a parent and child.
If you are concerned about a specific scenario or property, a real estate attorney or senior title agent in your area should be able to give you a good, quick answer with regards to the way the property is recorded and the rights of all parties involved.