Dariocg,
Yes, there are various ways to do it. Here is one:
1. Assign both resources at 100% each via Resources > Assignments > Assign Resources
2. Go to the Task Usage view and set the timescale for Months and Weeks
3. Set the timescale values to zero for the 3 weeks during which resource A will not work on the task
Hope this helps.
John