BUG: Groupby.transform('size') fails for multicolumn frame
Adding tests for #27467 surfaced some bugs:

```python
from pandas import *
df = DataFrame(dict(a=[0, 0, 0, 1, 1, 1], b=range(6)))
g = df.groupby(np.repeat([0,1], 3))
# ok
print(g.size()) 
#fails
g.transform('size') 
TypeError: Transform function invalid for data types
```