Yes, in principle, you can buy property in the Netherlands while living abroad. However, being allowed to purchase a home does not automatically mean that you will qualify for a Dutch mortgage.
Mortgage options for non-residents are more limited, as only a selection of lenders will consider applications from people who live outside the Netherlands. Your country of residence, income, employment, relocation plans and the intended use of the property will all affect what may be possible.