The security guards are violating the law. As said by Ken above, all beaches in the Dominican Republic are public back to 60 meters from the high water line. Only access through another person's property can be private, but if you arrive by the beach itself or by sea, by law you cannot be asked to leave. Now, as said by Ken above, in practice, hotels are limiting the access taking advantage that most people do not know the law. Once in Playa Dorada a Supreme Court justice was impeded access, and that led to press headlines reaffirming the fact that beaches are public.
The problem in part is because of lack of education on behalf of many Dominicans that do not understand that loud music and littering is not a desired part of a beach experience.
Recently, visited Bayahibe beach in La Romana and entered the area that is taken care of by Casa del Mar resort. The security personnel approached us asking us if we needed anything, and I just said no. Then myself and my family went about our own business of setting up our place on the beach. We were not further molested.
Note there is a beach area in Playa Dorada at the place called Club de Playa that as far as I am aware is open to the general public.