If real property acquired by the department under this chapter is not sold to a public or private entity authorized to operate rail service within six years of its acquisition by the department, the department may transfer and convey the property to the United States, its agencies or instrumentalities, to any other state agency, or to any county or city or port district of this state when, in the judgment of the secretary, the transfer and conveyance is consistent with the public interest. Whenever the secretary makes an agreement for any such transfer or conveyance, the secretary shall execute and deliver to the grantee a deed of conveyance, easement, or other instrument, duly acknowledged, as necessary to fulfill the terms of the agreement. All moneys paid to the state of Washington under this section shall be deposited in the essential rail banking account of the general fund.