Can the agent charge expenses if the sale does not go through?

Usually yes, unless the agreement or local custom says otherwise. The agent can be reimbursed expenses by whoever gave the assignment, even if the deal does not close (Civil Code art. 1756). The commission is different: it is due only when the deal is concluded. In practice, expenses and the commission are two separate items. Check any expense clause before you sign. Full guide: who pays the real estate agent’s commission in Italy.