You should be able to drive in these other states if you have a valid license in Massachusetts. You did not mention if you have a full license or only a Junior Operator's License (JOL). The MA Registry of Motor Vehicles (RMV) states that the JOL is a driver's license that is entitled to recognition in other states in case you have this type of license.
The MA RMV goes on to say with a JOL you must obey the traffic laws of the state you will be driving in. You should check with that state's Division of Motor Vehicles as other states may have more restrictive provisions for junior operators. You are subject to all of the provisions of the Massachusetts JOL law.
If the Massachusetts Registrar receives information from the other state indicating that you were operating in violation of the Massachusetts passenger restriction, she may take action to suspend your "Junior Operator's License.
Either with the JOL or full driver's license from MA you should be able to drive in Connecticut. Connecticut's Department of Motor Vehicles states that if you are at least 16 years of age are not a resident of CT, you may drive here with your out of state permit adhering to the same restrictions that have been placed on your permit. You must be under the instruction of a licensed driver who has held a license for at least four years.
So if a 16 year old with only a learner's permit may drive in Connecticut then you should be able to drive there with a full or junior MA driver's license. To make sure there will not be any conditions or restrictions placed on you while you are operating a vehicle in CT you can contact their DMV.
Neither the Rhode Island Division of motor vehicles site nor RI handbook gives any information on if you can drive in the state with an out of state permit. An out of state full license though should be recognized. Before driving in RI though you may want to contact their DMV to find out their laws and any conditions you may need to follow as a driver that is under the age of 18.