You should have told the police that you were not licensed and couldn't lawfully move the car. They could have ticketed you anyway, given that when they arrived you were behind the wheel operating the car, even if not yet in the act of moving it. You then topped it off by lying to the police and claiming you couldn't find your license after you had driven to the safe location.

Given your situation when they arrived and your choice not to tell them that you were unlicensed, although your lawyer may want to give it a try anyway, I'm not picturing a court accepting that you only drove without a license because the police told you that the car was unsafe in that particular location.

Having come across you under the circumstances, with you behind the wheel of your boyfriend's broken down car blocking an exit ramp and posing a hazard to other motorists, it's perfectly reasonable for them to ask to see your license.
Quote Quoting MGL Chapter 90: Section 10. Operation of motor vehicle without license; members of armed forces; nonresidents; suspension or revocation of license
No person under sixteen years of age shall operate a motor vehicle upon any way. No other person shall so operate unless licensed by the registrar unless he possesses a receipt issued under section eight for persons licensed in another state or country or unless he possesses a valid learner’s permit issued under section eight B, except as is otherwise herein provided or unless he is the spouse of a member of the armed forces of the United States who is accompanying such member on military or naval assignment to this commonwealth and who has a valid operator’s license issued by another state, or unless he is on active duty in the armed forces of the United States and has in his possession a license to operate motor vehicles issued by the state where he is domiciled, or unless he is a member of the armed forces of the United States returning from active duty outside the United States, and has in his possession a license to operate motor vehicles issued by said armed forces in a foreign country, but in such case for a period of not more than forty-five days after his return. The motor vehicle of a nonresident may be operated on the ways of the commonwealth in accordance with section three by its owner or by any nonresident operator without a license from the registrar if the nonresident operator is duly licensed under the laws of the state or country where such vehicle is registered and has such license on his person or in the vehicle in some easily accessible place. Subject to the provisions of section three, a nonresident who holds a license under the laws of the state or country in which he resides may operate any motor vehicle of a type which he is licensed to operate under said license, duly registered in this commonwealth or in any state or country; provided, that he has the license on his person or in the vehicle in some easily accessible place, and that, as finally determined by the registrar, his state or country grants substantially similar privileges to residents of this commonwealth and prescribes and enforces standards of fitness for operations of motor vehicles substantially as high as those prescribed and enforced by this commonwealth

Notwithstanding the foregoing provisions, no person shall operate on the ways of the commonwealth any motor vehicle, whether registered in this commonwealth or elsewhere, if the registrar shall have suspended or revoked any license to operate motor vehicles issued to him under this chapter, or shall have suspended his right to operate such vehicles, and such license or right has not been restored or a new license to operate motor vehicles has not been issued to him. Operation of a motor vehicle in violation of this paragraph shall be subject to the same penalties as provided in section twenty-three for operation after suspension or revocation and before restoration or issuance of a new license or the restoration of the right to operate