Yes, this is possible and something that the moderators are aware of. I'd even argue that this is status-bydesign, as long as you don't abuse it.
Every flag on a user's post is displayed in the profile page for that particular user (can be seen only by mods). This is helpful when action needs to be taken against them. It also shows who raised that flag. So if a post truly fits this description:
This question has severe formatting or content problems. This question is unlikely to be salvageable through editing, and might need to be removed
then flag it and close and get your free point! In other words, if you would've flagged it even without 4 close votes, then there is nothing wrong in flagging before closing. I do this sometimes if a post is so horribly bad, so that the mods will be aware of the issue if it comes to taking an action.
However, other flags are not dismissed. Flags to the moderator (you type something in) are not dismissed and if you flag "does not belong here", it automatically converts it to a close vote if you have 3k. Needless to say, spam/offensive flags should not be misused because of the repercussions it has for the flagged user.
Note that mods can also see your entire flagging history. So if you have a string of "very low quality" flags just before your close vote and the post is not worthy of it, then you better watch out.